The SQLite ADO.Net documentation (sqlite.phxsoftware.com) for the ExecuteScalar () query method reads: "Run the command and return the first column of the first row of the result set (if any) or null if there is no result set returned." I created a table:
create table users ( id integer primary key, name text )
And executed the queue using ExecuteScalar ():
select ( id ) from users where name = @name
But, itβs very strange - I canβt drop the retur value to 'int', only to 'long'! Why is it that the "id" field is defined as an "integer" in the database, and not "bigint"?
source
share