Home » Developer & Programmer » Forms » how to update the records
how to update the records [message #245353] Sat, 16 June 2007 05:37 Go to next message
rajat_chaudhary
Messages: 141
Registered: November 2006
Location: india
Senior Member

hi everyone,
I have a module in FORMS6i .
In that form when a user runs it user will get a drop down list(popup/combo list) and when the user select any value from the list then all the data filled in their corresponding fields.

(list is populted on the trigger ---- when-new-block-instance)

The item on which the list is populated is "primary key".
now when i changed any value after selecting any value from the list i got two errors:

1. list cann't be populated ( even the list available at there)
2. ora-00001 (primary constraint error)

i think second error is generated because oracle tries to insert a new record of the same selected value ,which violate the constraint.

but actually i don't want to insert the new record.
i want to update the data of that particular selected value.

how to change the form in "changed" mode by which the value get update and the list still populated.

REGARDS
RAJAT CHAUDAHRY
Re: how to update the records [message #245507 is a reply to message #245353] Sun, 17 June 2007 23:38 Go to previous messageGo to next message
djmartin
Messages: 10180
Registered: March 2005
Location: Canberra ACT Australia
Senior Member
Account Moderator
Create your list, use 'enter_query' to go into 'query' mode, use the list (via a 'show_lov' command) to populate your search term, then use 'execute_query' to gets its details back from the database. Then when you update the information you will be working on the database copy, not a new copy of existing data.

David
Re: how to update the records [message #246742 is a reply to message #245507] Thu, 21 June 2007 13:56 Go to previous message
rajat_chaudhary
Messages: 141
Registered: November 2006
Location: india
Senior Member

hi djmartin,
u are saying that
1. first to go to "enter_query" mode
2. then to populate list
3. then execute_query on the selection of the list item.

if i am not understanding exactly "ok" then
please reply with points.
by the way thanks so much
bye

REGARDS
RAJAT CHAUDHARY
Previous Topic: master-detail block depepndency
Next Topic: Please Help......Using Cursor for picking up values at runtime
Goto Forum:
  


Current Time: Thu Dec 08 06:16:57 CST 2016

Total time taken to generate the page: 0.08701 seconds