Search code examples
delphidelphi-2010dbexpress

copy records in a master/detail clientdataset delphi dbexpress


How can I copy the information of a record from a master/detail clientdataset to a new record or to an existing one.

For example I want to copy te data of invoice No. 100 to Invoice No. 150 or the information of invoice No. 100 to a new Invoice

With IBX I did that with storedprocedures but I am running into trouble with clientdataset with 'lock conflict on no wait transaction' when I apply the updates, i think its becasue the information is already on the server side.

Thanks in advance


Solution

  • 'Lock conflic on no wait transaction'?

    AFAIR, it's an Interbase/Firebird error. It could mean that other connection modified the record and still doesn't committed yet....

    UPDATE: Other things that came to mind:

    • Have you revised your DBX connection configuration? If you don't know/ignore what CommitRetaining is/do, make sure it's configured to FALSE. Otherwise, other problems will arise...

    • On Firebird/Interbase, you can only commit/rollback from Client application. SPs have no business with transaction control.