Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.
Gets the automatically generated ULCommand object required to perform insertions on the database.
Public Function GetInsertCommand() As ULCommand
public ULCommand GetInsertCommand();
The automatically generated ULCommand object required to perform insertions.
After the SQL statement is first generated, the application must explicitly call the RefreshSchema if it changes the ULDataAdapter.SelectCommand in any way. Otherwise, the GetInsertCommand method will still be using information from the previous statement, which might not be correct. The SQL statements are first generated when the application calls either the ULDataAdapter.Update or the GetInsertCommand method.
InvalidOperationException - The ULCommandBuilder.DataAdapter has not been initialized.
The DataAdapter.SelectCommand property has not been initialized.
The DataAdapter.SelectCommand.Connection property has not been initialized.
Dynamic SQL generation for the InsertCommand is not supported against a SelectCommand that does not return any modifiable columns.
Dynamic SQL generation is not supported against multiple base tables.
Dynamic SQL generation is not supported against a SelectCommand that contains duplicate columns.