dynamic sql generation is not supported against multiple base tables

后端 未结 4 1700
死守一世寂寞
死守一世寂寞 2020-12-21 16:53

I tried to add a new row to a Table in an SQL DB, but I had a problem :

dynamic sql generation is not supported against multiple base tables

4条回答
  •  轮回少年
    2020-12-21 17:43

    You can't use an SqlCommandBuilder here:

    Automatically generates single-table commands that are used to reconcile changes made to a DataSet with...

    The key words here being "single-table". It has no way to reverse engineer from the SELECT statement how a specific update should be applied (e.g. if you NULL all of the columns from the right side of a left join, should it delete the row, or set each column to null.

    You need to author appropriate Insert, Update and Delete commands on the SqlDataAdapter.

提交回复
热议问题