[QODBC-Desktop] How to use Batch Statements with QODBC
Posted by Juliet (QODBC Support) on 04 June 2010 07:44 AM
|
|
How to use Batch Statements with QODBCNote: There are three stored procedures for batch statements which are SP_BATCHCLEAR, SP_BATCHSTART, and SP_BATCHUPDATE. SP_BATCHCLEARSyntax and Instruction SP_BATCHCLEAR table name - Clears any cached batch statements for the given table. This is an executed query and does not return a recordset. Example SP_BATCHCLEAR Customer SP_BATCHSTARTSyntax and Instruction SP_BATCHSTART tablename - Starts batch mode inserts/updates for a given table. All inserts or updates issued after this statement on this table will be cached and not transmitted to QuickBooks until the SP_BATCHUPDATE command is issued. This is an execute command and does not return a recordset. Example SP_BATCHSTART Customer SP_BATCHUPDATESyntax and Instruction SP_BATCHUPDATE tablename - Submits a batch of previously cached inserts/updates for a given table. All inserts or updates issued since the sp_batchstart statement will be transmitted to QuickBooks. Use sp_lastinsertID to retrieve the status of the batch update. This is an execute command and does not return a recordset. Example SP_BATCHUPDATE Customer
A Complete ExampleBatchStart BatchInsert1 BatchInsert2 BatchUpdate | |
|
Is this to be one long statements that is executed once or does each statement need executed individually?
You can execute statement individually through Batch Statements.
Please refer below mentioned link for How to insert InvoiceLine item to an existing Invoice:
http://support.flexquarters.com/esupport/index.php?/Knowledgebase/Article/View/2542/0/how-to-insert-invoiceline-item-to-an-existing-invoice