Vincent Zhen

Greenhorn
+ Follow
since Nov 04, 2006
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Vincent Zhen

Start to prepare for SCBCD 5 today, schedule exam after 2 months.
https://www.certmanager.net/sun_assignment/
login and goto "test history", you will get the part 3 result.
Login the assignment management system, maybe the part 3(asssignment) assessment result has been there.
I took part 1 at June.07 2009, uploaded part 2 at June.30 2009 morning and took the part 3 at June.30 2009 afternoon. Got passed part 3 at July.06 2009.
Hi, change your trigger as following(add a "if :NEW.STUDENT_ID is null " statement, then when hibernate increasing the sequence by 1, oracle trigger will not do it again, but other application can still use the trigger to get a increasing by 1 ID
):

CREATE OR REPLACE TRIGGER TRG_STUDENT_INSERT BEFORE INSERT ON STUDENT
FOR EACH ROW
BEGIN
if :NEW.STUDENT_ID is null
then SELECT STUDENT_SEQ.NEXTVAL INTO :NEW.STUDENT_ID FROM DUAL;
end if;
END;