Home » Developer & Programmer » Forms » Oracle Form commit VS store pro commit
Oracle Form commit VS store pro commit [message #87197] Mon, 13 December 2004 23:22 Go to next message
skc
Messages: 14
Registered: September 2004
Junior Member
I've posted the following before but can't get fully understood... so anyone can help?

In my interpretation, the SQL commit command in Oracle Form commits everything in the Form,
but when a store pro is called in the Form and DML is involved in the pro,
the Oracle Form commit does not commit those DML change in the pro as they are not within the Form; vice versa.

Let say, the store pro ABC has DML but no Commit (as I try to commit the change in Oracle Form),
and the ORacle Form call the store pro in this way (maybe in one of the item trigger, etc.):

declare
ok_flag varchar2(1);
BEGIN
ok_flag := ABC;
-- ABC has OUT parameter of varchar2(1); 'Y' if no error, 'N' if error found.

IF ok_flag = 'Y' THEN
COMMIT;
ELSE
ROLLBACK;
END IF;
END;

Now i only want to Commit the changes in store pro but NOT Form.
But the 'Commit;' in Form commits everything in the Oracle Form but not DML in store pro.
So, basically, I think Oracle Form and the store pro holds 2 different sessions but not the same...... Right?
Re: Oracle Form commit VS store pro commit [message #87261 is a reply to message #87197] Wed, 15 December 2004 13:32 Go to previous message
Just John
Messages: 69
Registered: November 2004
Member
Wrong!

Forms has one session but only commits the form when you issue the COMMIT command from forms. (it actually has another procedure with the same name)

You just need to use STANDARD.COMMIT this will perform the commit which is in the database package STANDARD.

for as in your example:

IF ok_flag='Y' THEN
STANDARD.COMMIT;
ELSE
....

any help?
Previous Topic: Check Box! URGENT
Next Topic: text_io problem
Goto Forum:
  


Current Time: Sun Sep 08 03:43:00 CDT 2024