Home » Developer & Programmer » Forms » Oracle Form commit VS store pro commit
Oracle Form commit VS store pro commit [message #86932] Sun, 21 November 2004 23:18 Go to next message
skc
Messages: 14
Registered: September 2004
Junior Member
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 it, the Oracle Form commit does not commit those DML change as they are not within the Form; vice versa.  So is it correct or not?  Thank you!!
Re: Oracle Form commit VS store pro commit [message #86936 is a reply to message #86932] Mon, 22 November 2004 04:33 Go to previous messageGo to next message
Adi
Messages: 38
Registered: May 2002
Member
hi skc,
see the commit in the stored procedure and in the SQL works one and the same i mean to say that the commit given in the sql and the commit from the stored procedure works the one and the same but there is small change which is the big one . if u just give the insert and no commit in the form stored pro then the changes in the stored pro are not reflected in the sql and vice versa.
Re: Oracle Form commit VS store pro commit [message #86943 is a reply to message #86936] Mon, 22 November 2004 16:03 Go to previous messageGo to next message
skc
Messages: 14
Registered: September 2004
Junior Member
Sorry...can you explain in a easier way..hard to understand
Re: Oracle Form commit VS store pro commit [message #86959 is a reply to message #86943] Wed, 24 November 2004 02:09 Go to previous messageGo to next message
Adi
Messages: 38
Registered: May 2002
Member
hi skc,

in forms after all DML Statements at the end just give the commit this works same as the commit in the SQL. But after the commit if you are are placing any DML statements these wont get reflected in the Database.
Re: Oracle Form commit VS store pro commit [message #86961 is a reply to message #86932] Wed, 24 November 2004 04:13 Go to previous messageGo to next message
rama krishna
Messages: 97
Registered: December 2001
Member
U need to Understand how Transaction Processing Happens in Oracle...
A Transaction Starts with a commint and ends with a Commit or Roll back...so in between whatever DML statements u give in a session all those will be either commited or Rolled back..
Now in ur case..u r calling a Oracle Stored Procedure from Forms, which have some DML statements..so the Stored Procedure gets executed in the same Session...So if u give Commit in forms all the DML in Stored Procedure gets commited...

Cheers
Ram
Re: Oracle Form commit VS store pro commit [message #86975 is a reply to message #86961] Thu, 25 November 2004 17:38 Go to previous messageGo to next message
skc
Messages: 14
Registered: September 2004
Junior Member
The problem is.... 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 #86976 is a reply to message #86959] Thu, 25 November 2004 17:41 Go to previous message
skc
Messages: 14
Registered: September 2004
Junior Member
I know Form Commit will trigger a SQL Commit coz it's how the Oracle Form architecture goes.... but what i mean is, is Form Commit and Store Pro Commit resides in 2 different sessions?
Previous Topic: Re : Window Scroll bar
Next Topic: text item value
Goto Forum:
  


Current Time: Sun Jun 02 11:48:54 CDT 2024