Home » U++ Library support » U++ SQL » Updated Sqlite3 plugin
Re: Updated Sqlite3 plugin [message #4144 is a reply to message #4140] |
Tue, 25 July 2006 10:50   |
|
aroman wrote on Tue, 25 July 2006 04:07 |
EDIT: PLEASE NOTE THAT DATABASES CREATED WITH THIS VERSION ARE NOT COMPATIBLE WITH THE PREVIOUS VERSION!! See the sqlite homepage for details.
|
Thanks for info.
BTW: I think upp sql interface is missing two importnant functions:
int GetInsertedId() - returns last inserted id if column has "auto increment" atrribute
int GetSqlCode() - returns native sql error code as integer value.
for sqllite3:
int GetInsertedId()
{
return sqlite3_last_insert_rowid(db);
}
for ms sql server (and it seems for oledb too):
int GetInsertedId()
{
static Sql sql("select @@identity", db);
sql.ExecuteX();
sql.Fetch();
return (int) sql[0];
}
I don't know how it should looks for oracle.
|
|
|
Goto Forum:
Current Time: Mon Aug 11 23:49:16 CEST 2025
Total time taken to generate the page: 0.08599 seconds
|