Skip to Main Content

Java Development Tools

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!

Auto increment id is not working for DB Sequence ID (JDev 12.2 JSF 2.2)

Mehdi EsteghamatianMar 27 2017 — edited Mar 27 2017

hi All,

I have an Entity Object with its id set to DBSequence on database side I have a trigger for before insert for each row which is supposed to assign the ID field.

I get the below error when I run the application module for some

pastedImage_0.png

The before each row trigger is like below:

set define off;

create or replace trigger AST_ASSET_LOCATIONS_trg before insert on "GHARB2"."AST_ASSET_LOCATIONS"

for each row

begin

if inserting then if :NEW."ID" is null then

 select AST\_LOCN\_Q.nextval into :NEW."ID" from dual;

end if; end if;

end;

Error Message

Attribute Id in AssetAM.AstAssetLocationsVO is required.

pastedImage_5.png

Please let me know

Thank you,

J

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 24 2017
Added on Mar 27 2017
5 comments
842 views