Confirmation of Execution of SQL code
From: Shahzard (shahzard_at_vampire.net)
Date: 03/26/04
- Next message: John Faris: "Re: TAdoBlobStream read error"
- Previous message: Brian Bushay TeamB: "Re: Multiple-step Operations Generated Errors!"
- Next in thread: Brian Bushay TeamB: "Re: Confirmation of Execution of SQL code"
- Reply: Brian Bushay TeamB: "Re: Confirmation of Execution of SQL code"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 26 Mar 2004 02:25:28 -0800
Hi,
I've created a method where there's two tables for 2 purposes but two have the same fields. Assume that table1 is for Entry purposes and table2 is more likely a History table of table1.
This method is, after inserting some data to table1, after a button click event or any other event makes these entered data to be exported to table2. To do that I use TADOQuery and wrote the following Query:
"INSERT INTO table2 (CompID, IssueDate, ShareHolderID, SecurityCode, Quantity)
Select CompID, IssueDate, ShareHolderID, SecurityCode, Quantity from table1".
and made to Execute at Run time when the user presses the export button. After inserting every data to table2 I will be deleting the data in table1. To do that I used an another TADOQuery and wrote the SQL code as:
"Delete from table1" and execute it.(TADOQuery.ExecSQL;)
My question comes here, as I want to know how to confirm that, all the data has been transfered before calling the procedure of deleting the data in table1. I know that SQL command will never go wrong, but its better take precautions. Pls. somebody help in this.
Thanx,
Awaiting a response in anticipation.
Shahzard.
- Next message: John Faris: "Re: TAdoBlobStream read error"
- Previous message: Brian Bushay TeamB: "Re: Multiple-step Operations Generated Errors!"
- Next in thread: Brian Bushay TeamB: "Re: Confirmation of Execution of SQL code"
- Reply: Brian Bushay TeamB: "Re: Confirmation of Execution of SQL code"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]