Prepared Statement

  • I have a set (batch) of tranasctions which I am trying to insert in to the DB. I want to know if it is possible to use prepared statements. I know it is possible to use Prepared Statements 'exec sp_executesql' with ODBC but we are using native xml support (templates) to port data in and out of the DB. Is it possible to call 'exec sp_executesql' directly from the XML template.

    ex:

      exec sp_executesql N' EXEC usp_Test @param1, @param2 ', N' @param1 nvarchar(100), @param2 nvarchar(100) ', N'@param1', N'@param2'

    If this does not make any sense or any user have has problems, is there a better way of doing it. I am using VB (COM) to do this and the dataset is saved in a XML file on the Web Server (different from the Database Server).

    Any suggestions...

    Thanks

  • I'm not sure on that one.  But if you are using a VB COM object, you may wish to use the DTS.BulkInsertTask object to perform your batch processing.  You can use the DTS.Connection object to get a reference to you xml file.

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply