I am trying to insert a row (working version)
_masterDb.Query(table.FullName()).Insert(value.ForDatabase);
//raw sql:
//INSERT INTO [mst].[TableOne] ([Name], [TableCol]) VALUES ('www', 'ddf')
But if I want to fetch Id
of last inserted row
_masterDb.Query(table.FullName()).InsertGetId<int>(value.ForDatabase);
//raw sql:
//INSERT INTO [mst].[TableOne] ([Name], [TableCol]) VALUES ('www', 'ddf'); SELECT SCOPE_IDENTITY() as Id
For this, I get error Parameter count mismatch
?? Where is the parameter mismatch?
Note: If I copy paste the aboe Raw SQL generate, it does work.