Home » Developer & Programmer » Forms » search and update (oracle forms 10g windows)
search and update [message #546996] Sun, 11 March 2012 01:28 Go to next message
furqan
Messages: 115
Registered: January 2012
Location: Hyderabad
Senior Member


hi
i hav a table in database with name TBH.in that table there are 25 to 30 columns.its a material details table.
by using add material form i insert all the details of the material in the table.2 colums have primary key(material id and material code).
now iam making search and update form.on material code item i have WHEN-MOUSE-CLICK-TRIGGER and calling LOV and displaying
record.

but the problem is when iam making changes in some fields its giving error ...UNABLE TO INSERT....FRM-40508:ORACLE error:unable to insert record.

when i check display error its showing

ORA-00001: unique constraint (DETA.SYS_C006356) violated..

please help...


Re: search and update [message #546997 is a reply to message #546996] Sun, 11 March 2012 03:03 Go to previous messageGo to next message
Michel Cadot
Messages: 68666
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
ORA-00001: unique constraint (%s.%s) violated
 *Cause: An UPDATE or INSERT statement attempted to insert a duplicate key.
         For Trusted Oracle configured in DBMS MAC mode, you may see
         this message if a duplicate entry exists at a different level.
 *Action: Either remove the unique restriction or do not insert the key.

Regards
Michel
Re: search and update [message #547005 is a reply to message #546997] Sun, 11 March 2012 05:14 Go to previous message
cookiemonster
Messages: 13925
Registered: September 2008
Location: Rainy Manchester
Senior Member
You haven't populated the block using execute_query have you?
I assume you've written a select statement to manually populate the block.
Do that and forms thinks all the records are new records and will try and insert them when you click on save.
Previous Topic: Form disconnect from database automatically
Next Topic: Updating BLOB Column
Goto Forum:
  


Current Time: Fri Jul 05 23:22:56 CDT 2024