Skip to Main Content

Java EE (Java Enterprise Edition) General Discussion

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

JSP rendering HTML source code occasionally

893088Oct 7 2011 — edited Oct 11 2011
I have project deployed on JBoss423 server. Sometimes while accessing a jsp page i am seeing the html source. I have already tried including the 'meta http-equiv="content-type" content="text/html; charset=utf-8"' and <%@ page contentType="text/html; charset=UTF-8" %> tags but still the error seems to not resolved. After the error comes if i refresh the page it works perfectly.

I am not able to find a genuine solution to this problem. The error is occurring on IE9 as well as firefox 7.0.1. I am not seeing this error when i use IE8.

Comments

Manjusha Muraleedas
Answer

Hi
Insertion to table home details is incorrect.

You specified only 3 columns F_NAME, M_NAME, C_NAME in column list and gave 4 values in value list.Please correct it.

INSERT INTO HOME_DETAILS

(F_NAME, M_NAME, C_NAME  )

values

(:old.F_NAME,

:old.M_NAME,

:old.C_NAME ,V_USERNAME);


Regards.

Manjusha

Marked as Answer by Aravind Kumar Sekar · Sep 27 2020
unknown-951199

[oracle@localhost ~]$ oerr ora 24344

24344, 00000, "success with compilation error"

// *Cause:  A sql/plsql compilation error occurred.

// *Action: Return OCI_SUCCESS_WITH_INFO along with the error code

//

John Spencer

There are other issues with your trigger in addition to the column list discrepancy.  You name the trigger HOME_BEFORE_DELETE, but define it as before insert.  The old values that you reference in the trigger body are not available in a before insert trigger.

John

UserMr

Your code should be like following:

Create tables:

create table home (F_NAME VARCHAR2(25),M_NAME VARCHAR2(25),C_NAME VARCHAR2(25));

create table home_details (F_NAME VARCHAR2(25),M_NAME VARCHAR2(25),C_NAME VARCHAR2(25),V_USERNAME varchar2(25));

Create Triggers:

CREATE OR REPLACE TRIGGER HOME_BEFORE_DELETE

BEFORE INSERT

ON HOME

FOR EACH ROW

DECLARE

V_USERNAME VARCHAR2(25);

BEGIN

SELECT USER INTO V_USERNAME FROM DUAL;

INSERT INTO HOME_DETAILS

(F_NAME, M_NAME, C_NAME,V_USERNAME  )

values

(:new.F_NAME,

:new.M_NAME,

:new.C_NAME ,V_USERNAME);

END;

Test:

insert into home values('a','b','c');
commit;

select * from home_details

Output:

a b c user1

1 - 4
Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Nov 8 2011
Added on Oct 7 2011
1 comment
734 views