Home » Developer & Programmer » Forms » Save changes.. but I have no changes to save..
Save changes.. but I have no changes to save.. [message #492872] Thu, 03 February 2011 05:54 Go to next message
ahazin
Messages: 39
Registered: August 2010
Member
hi guys, I currently have a master detail relationship but i have a problem. When a query is entered in my master block it automatically queries the detail block, this is fine, however , if i then want to enter a new query, thus entering query mode in the master block I get a prompt asking me if i want to save changes, but I havent made any changes.

I do however have an idea for the cause of the problem. I have 2 non database items on my detail block which are just there to provide additional information to the user. How they work is that when the id from the detail block is brought back I have in a post query trigger that I open a cursor and bring data back from another table and display it to the user in these NON database items. however i did not think this would cause a prompt to save changes as this inforrmation was going into a non databse item. I am simply assuming this is my problem.

Anyone any ideas how I could resolve this?

Thank you.
Re: Save changes.. but I have no changes to save.. [message #492874 is a reply to message #492872] Thu, 03 February 2011 06:11 Go to previous messageGo to next message
cookiemonster
Messages: 13938
Registered: September 2008
Location: Rainy Manchester
Senior Member
Do those non-database items have when-validate-item triggers?
Re: Save changes.. but I have no changes to save.. [message #492878 is a reply to message #492872] Thu, 03 February 2011 06:21 Go to previous messageGo to next message
ahazin
Messages: 39
Registered: August 2010
Member
yea, they do. It is to allow it to work in reverse, ie if the user knows the information fo that column it will go ahead and automatically fill in the other columns including the id column which IS a database item.

Ahh, i see what your getting at. The when validate item trigger executes and then that will then populate the id (which is a database item) with the same value as it already had hence causing the prompt.

Dont suppose you would have any idea of a way to solve this problem other than taking the when validate item trigger off?

Thanks for the help.

Re: Save changes.. but I have no changes to save.. [message #492885 is a reply to message #492878] Thu, 03 February 2011 06:59 Go to previous messageGo to next message
cookiemonster
Messages: 13938
Registered: September 2008
Location: Rainy Manchester
Senior Member
use set_item_property(<item>, item_is_valid, property_true) for each item after you set it in post-query. That'll stop the WVI triggers firing.
Re: Save changes.. but I have no changes to save.. [message #492896 is a reply to message #492885] Thu, 03 February 2011 07:40 Go to previous message
ahazin
Messages: 39
Registered: August 2010
Member
Excelent, thank you for your help. Smile

[Updated on: Thu, 03 February 2011 07:41]

Report message to a moderator

Previous Topic: Calling Two Different LOVs at same Textbox
Next Topic: icon images in oracle 10
Goto Forum:
  


Current Time: Tue Sep 17 16:25:22 CDT 2024