Get commandtext of TableAdapter Insert/Update/Delete Query RRS feed

  • Question

  • Hello anybody can help me? 

    I'm going to create a synchronization tools between a few of separated servers.

    (i'm using SQL Server 2005 and develop the windows application with TableAdapter)

    Here is the plan:

    Server A is parent server

    Server B, C, D is child server

    Whenever B, C, D execute any DML Command, it will create command text completed with parameter value.


    If i succesfully execute MasterLecture.insertQuery(txtCode.text, txtName.text, dtpBirthDate.value)

    I will get the command text: Insert into MasterLecture (Code, Name, BirthDate) values ('001', 'John', '01/01/1991')

    This command text will be collected to a table and will be emailed to parent server via xml on a schedule.


    My issue is, i can't find any method to get the command text (is this possible?).


    Also, i'm not sure this is the correct simplest way to have a few servers synchronized :(

    The internet connection in my country is very unstable so I can't have a WebService method here. Using SQL Server Integration System sounds great (but i haven't explored it yet because it seems not simple)

    Anybody can place some ideas/options here?


    Many Thanks before

    • Moved by T.J. --- MSFT Tuesday, December 14, 2010 1:01 AM Question about TableAdapter, moving to a better forum than the Transactions one. (From:Transactions Programming)
    Wednesday, November 24, 2010 8:18 PM

All replies