I have a simple problem with a not so simple solution... I am currently inserting some data into a database like this:
kompenzacijeDataSet.KompenzacijeRow kom
select last_insert_rowid();
And you will need to execute it as a scalar query.
string sql = @"select last_insert_rowid()"; long lastId = (long)command.ExecuteScalar(sql); // Need to type-cast since `ExecuteScalar` returns an object.