Im creating a new row in my datatable:
DataTable.Rows.Add(rowToAdd)
...and update the database:
SqlDA = New SqlClient.SqlDataAdapter(strSql,connectionString)
sqlCommBuild = New SqlClient.SqlCommandBuilder(SqlDA)
SqlDA.Update(DataTable)
The problem is: i want to know the primary key of the created row, which is an auto-increment number in my sql-server.
I cant update the dataset from the database, because, of course, i dont have the primary key...
DataTable.Rows.Add(rowToAdd)
...and update the database:
SqlDA = New SqlClient.SqlDataAdapter(strSql,connectionString)
sqlCommBuild = New SqlClient.SqlCommandBuilder(SqlDA)
SqlDA.Update(DataTable)
The problem is: i want to know the primary key of the created row, which is an auto-increment number in my sql-server.
I cant update the dataset from the database, because, of course, i dont have the primary key...