Skip to Main Content

Oracle Forms

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Removing LOV item and removing unwanted detail record

511309Aug 2 2006 — edited Aug 2 2006
Hi,

I have some problems on implementing master-detail block.
How can I avoid showing the unique constraint in detail block?
ORA-00001: unique constraint (SCOTT.PK_DTABLE) violated.

I use an LOV in the detail block to select the ItemID.
I would like to remove the ItemID which has been selected before from the LOV.
So the user won't be able to choose twice.
But, the LOV is based on Query, not static record group.
How can I do this?

- If possible, can I manually check the condition of unique violation?
I want to show with my 'own language' alert if it happen.
- Can I do merging to the detail record which share the same ItemID?
I mean, by calculating the quantity of the item.
Or have the form to do updating, instead of inserting, when found duplicate ItemID in detail?


Another problem,
Can I ask the Form to remove or ignore the detail record with specific criteria
before inserting it to the database?
i.e, automatically ignore or (remove) the detail record where Quantity = 0.
I know, we can use when-validate-item trigger to inform the user.
But I'd like to simply remove the "zero-quantity" item from being inserted.

Any help would be grateful.

Many thanks,


Imelda
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 30 2006
Added on Aug 2 2006
1 comment
479 views