GetUpdateCommand
SqlCommand updateCommand = CommandBuilder.GetUpdateCommand();
Returns a reference to the automatically generated
Command
object, which updates data within the data
source when the Update( )
method of the data
adapter is called.
If the SELECT command that is the basis of the automatically
generated UPDATE command is changed, the RefreshSchema( )
method must be called. Otherwise the
GetUpdateCommand( )
method returns a statement for
the previous schema.
Calling one of the GetDeleteCommand( )
,
GetInsertCommand( )
, or GetUpdateCommand( )
methods or the Update( )
method of the
DataAdapter
, generates all delete, insert, and
update command logic.