Home » Developer & Programmer » Forms » post_change trigger on item (Oracle Forms 10g)
post_change trigger on item [message #515485] Mon, 11 July 2011 18:41 Go to next message
nik.gujeran
Messages: 11
Registered: July 2011
Junior Member
Hello,

I am very new to oracle forms. I am asked to change an existing field (Category_Desc) from a data block (applications) from a current form with a different field (Facility) from another table (Places) that is not used in the current data blocks. How do i do that and how should i populate the data... The common string between the table used in the form (applications) and the non used table (Places) is the ID No.

Could someone help me make this change and also with a possible trigger to generate the data....

Thank you so much in advance.

Nick
Re: post_change trigger on item [message #515501 is a reply to message #515485] Tue, 12 July 2011 00:05 Go to previous messageGo to next message
Littlefoot
Messages: 21818
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
To populate that item (that doesn't belong to a table data block is based on), Use
  • WHEN-VALIDATE-ITEM trigger when inserting new values
  • POST-QUERY when querying existing data
Query (i.e. SELECT statement looks the same in both cases, something like
select p.facility
  into :block.facility
  from places p
  where p.some_id = :block.some_id;
Include exception handlers if you wish (such as NO-DATA-FOUND).

A POST-CHANGE trigger you mentioned in a topic title is not to be used any more. In the old days (Forms 3.0), it was the only option you had, but now it is here only for backward compatibility so - don't use it.
Re: post_change trigger on item [message #515642 is a reply to message #515501] Tue, 12 July 2011 10:39 Go to previous message
nik.gujeran
Messages: 11
Registered: July 2011
Junior Member
Thank you so very much littlefoot...

I really appreciate your help...

thanks
Nick
Previous Topic: REPLACE_MENU Problem
Next Topic: Starting an Oracle web form on computer startup
Goto Forum:
  


Current Time: Sun Sep 08 22:59:20 CDT 2024