Master / Detail Relation question [message #579743] |
Thu, 14 March 2013 15:39 ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
![](http://www.gravatar.com/avatar/903486378bcc2a973e29e42b718cb174?s=64&d=mm&r=g) |
scuts
Messages: 2 Registered: March 2013 Location: United States
|
Junior Member |
|
|
On a form I have 2 blocks, shown on different tabs. Relation created by forms wizard. The relation works great when navigating through the blocks, the details for the master are shown fine.
Example for this form is master block is a type of food. Detail block is list of ingredients.
When creating a new type of food, if it's = CAKE we insert records based on a select on another table into the ingredients table.
Else, the user has to manually create the ingredients.
Upon commit of the form on master block (must be saved to enable detail block tab), the ingredients are not displayed but are there. If I execute query by hitting F8, the records are present.
Why is the populate-details trigger not being fired or what am I missing?
|
|
|
Re: Master / Detail Relation question [message #579746 is a reply to message #579743] |
Thu, 14 March 2013 16:15 ![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 assume the insert of the child records is done from a trigger in the form?
Simple answer - because the form has no idea you've just made it insert child records for the newly inserted master.
Normally when you enter a new master there are no children, so why would it try to populate the block with records that shouldn't exist?
|
|
|
|
|
Re: Master / Detail Relation question [message #580034 is a reply to message #579748] |
Tue, 19 March 2013 09:35 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) |
![](http://www.gravatar.com/avatar/903486378bcc2a973e29e42b718cb174?s=64&d=mm&r=g) |
scuts
Messages: 2 Registered: March 2013 Location: United States
|
Junior Member |
|
|
Thanks for all of the feedback. I apologize I am now just getting back to this. I tried the manual execution by populate-details and did not have success. Yes the detail records were inserted by a trigger. In the end I had to clear the form on commit and take the user back to the key block allowing them to see the master id of the record and navigate back through to see the records.
While not the ideal solution it will have to do for now.
|
|
|