How to remove status changed from DataBlock [message #619409] |
Tue, 22 July 2014 05:16 ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
![](http://www.gravatar.com/avatar/d5f3c8e6ec001cc2009d91a09b051b18?s=64&d=mm&r=g) |
alex_shynk
Messages: 22 Registered: July 2014
|
Junior Member |
|
|
I chose record in DataBlock use LOVs. But it change DataBlock's status to inserted.
When form closing I get next message 'Do You want to save the changes you made?'
How to change status to unchanged for one DataBlock from multi DataBlocks?
I have tried next decision
trigger PRE-INSERT:
FORMS_DDL('SAVEPOINT B');
trigger POST-INSERT:
FORMS_DDL('ROLLBACK TO B');
But not successful and i do not know why.
[Updated on: Tue, 22 July 2014 05:16] Report message to a moderator
|
|
|
Re: How to remove status changed from DataBlock [message #619413 is a reply to message #619409] |
Tue, 22 July 2014 05:40 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
cookiemonster
Messages: 13937 Registered: September 2008 Location: Rainy Manchester
|
Senior Member |
|
|
I'm not sure why you thought savepoint and rollback would be useful here.
The correct solution generally is to ensure the status doesn't go wrong in the first place.
In standard forms processing you would go into enter-query mode, pick a value from the list and then use execute-query.
Alternatively you would have a non-database control block in which you enter the query criteria and use that to set a where clause on a database block, then you use execute-query.
With either approach you shouldn't end up in this situation.
So what exactly are you doing that causes the datablock to go to insert status?
|
|
|
Re: How to remove status changed from DataBlock [message #619446 is a reply to message #619413] |
Tue, 22 July 2014 09:32 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) |
![](http://www.gravatar.com/avatar/d5f3c8e6ec001cc2009d91a09b051b18?s=64&d=mm&r=g) |
alex_shynk
Messages: 22 Registered: July 2014
|
Junior Member |
|
|
cookiemonster wrote on Tue, 22 July 2014 05:40I'm not sure why you thought savepoint and rollback would be useful here.
The correct solution generally is to ensure the status doesn't go wrong in the first place.
In standard forms processing you would go into enter-query mode, pick a value from the list and then use execute-query.
Alternatively you would have a non-database control block in which you enter the query criteria and use that to set a where clause on a database block, then you use execute-query.
With either approach you shouldn't end up in this situation.
So what exactly are you doing that causes the datablock to go to insert status?
I set "DataBase Data Block: NO" for DataBlock and it solved my problem. Thank You.
[Updated on: Tue, 22 July 2014 09:32] Report message to a moderator
|
|
|