Results 1 to 3 of 3

Thread: Update the whole table, is it possible ?

  1. #1

    Thread Starter
    New Member
    Join Date
    Sep 2005
    Posts
    14

    Update the whole table, is it possible ?

    I have a dataTable and now i want to update the whole table to database instead of updating each row

    Is there any way to do it ?

    thx in advance

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: Update the whole table, is it possible ?

    You need to assign Command objects, with the appropriate SQL code in their CommandText properties, to the DeleteCommand, InsertCommand and UpdateCommand properties of a DataAdapter and then call its Update method. There is plenty of ADO.NET information available on MSDN, from the tutorial links in my signature, in the 101 samples and from many other sources. I suggest you roll your sleeves up and do some reading.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  3. #3
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170

    Re: Update the whole table, is it possible ?

    Isn't updating the whole table updating it row by row anyways?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width