Home » Developer & Programmer » Forms » Issue with PL/SQL update (Oracle forms 10G and Oracle 9i)
Issue with PL/SQL update [message #334040] Tue, 15 July 2008 04:50 Go to next message
bahubcd
Messages: 40
Registered: July 2007
Location: Bangalore
Member
Hi all,
The issue is that I have a form which has 6 data blocks based on 6 tables. The Primary key for all the tables is item_number and eff_date. The form can open for Item levels 1,2 and 3.

There is an option for the user that whenever the user updates parent item records for the data blocks, he can cascade the changes to the child items.

As i have told earlier that the data block's table has Primary key as item_number and eff_date combination. Now The user for Level 1 item updates the row for one of the table's data block and he changes the eff_date for a row. The application promts the user to cascade/copy the changes to the L-2 and L-3 items and user says yes. The changes for L-1 are posted via form's data blocks The cascade is handled in the backend PLSQL package function. The issue now is to update the same row for L-2/L-3 item that was altered for the Level-1 item from the forms. But the row has lost its uniqueness as the effective data has been changed.

Hope the requirement is clear. Can someone suggest the best possible way of implementing the functionality.

Thanks for the help and feedback in advance.
Re: Issue with PL/SQL update [message #339139 is a reply to message #334040] Wed, 06 August 2008 21:15 Go to previous message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Either:
1) Use a different key as the primary key.
Or:
2) Copy the old data to new entries with the new data and then delete the old entries. That is, insert/delete versus update.

David
Previous Topic: hyper link
Next Topic: probelem with radio group population
Goto Forum:
  


Current Time: Mon Feb 10 00:33:20 CST 2025