How to update datatable in memory without dataadapter?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • =?Utf-8?B?UGV0ZXI=?=

    #1

    How to update datatable in memory without dataadapter?

    A datatable is returned from a .NET method. Since there is no dataadapter
    in this case, how can I update a column for all the rows in that datatable?
  • Spam Catcher

    #2
    Re: How to update datatable in memory without dataadapter?

    =?Utf-8?B?UGV0ZXI=?= <Peter@discussi ons.microsoft.c omwrote in
    news:A2D37C2A-0445-4EAA-B612-3702D9ABED99@mi crosoft.com:
    A datatable is returned from a .NET method. Since there is no
    dataadapter in this case, how can I update a column for all the rows
    in that datatable?
    Do you have access to the database?

    Comment

    • =?Utf-8?B?UGV0ZXI=?=

      #3
      Re: How to update datatable in memory without dataadapter?

      No. The datatable is the one returned by
      DbDataSourceEnu merator.GetData Source. So, I just want to update the
      datatable in memory.

      "Spam Catcher" wrote:
      =?Utf-8?B?UGV0ZXI=?= <Peter@discussi ons.microsoft.c omwrote in
      news:A2D37C2A-0445-4EAA-B612-3702D9ABED99@mi crosoft.com:
      >
      A datatable is returned from a .NET method. Since there is no
      dataadapter in this case, how can I update a column for all the rows
      in that datatable?
      >
      Do you have access to the database?
      >

      Comment

      • Spam Catcher

        #4
        Re: How to update datatable in memory without dataadapter?

        =?Utf-8?B?UGV0ZXI=?= <Peter@discussi ons.microsoft.c omwrote in
        news:1A38518A-0EDE-4D3F-931F-062F0921F97C@mi crosoft.com:
        No. The datatable is the one returned by
        DbDataSourceEnu merator.GetData Source. So, I just want to update the
        datatable in memory.
        If you do not have access to the data - you cannot send updates back to the
        DB.

        A datatable is a disconnected representation of the database. It has no
        access to the underlying data source.

        Comment

        • =?Utf-8?B?UGV0ZXI=?=

          #5
          Re: How to update datatable in memory without dataadapter?

          Yes and I don't want to update any datasource in this case (actually don't
          know the datasource). I have resolved the issue by using for loop and assign
          value to column.

          "Spam Catcher" wrote:
          =?Utf-8?B?UGV0ZXI=?= <Peter@discussi ons.microsoft.c omwrote in
          news:1A38518A-0EDE-4D3F-931F-062F0921F97C@mi crosoft.com:
          >
          No. The datatable is the one returned by
          DbDataSourceEnu merator.GetData Source. So, I just want to update the
          datatable in memory.
          >
          If you do not have access to the data - you cannot send updates back to the
          DB.
          >
          A datatable is a disconnected representation of the database. It has no
          access to the underlying data source.
          >

          Comment

          Working...