On 10 May 2010, at 4:11pm, Carlos Andrés Ramírez C. wrote:

> I was breaking my head trying to figure out how to obtain the last 
> inserted row's ID --- using SQLite from Ruby.
> 
> I found 'last_insert_rowid()' in your documentation at   
> http://www.sqlite.org/lang_corefunc.html   and still did not do it.
> 
> After spending a lot of time searching, I found that it was not 
> 'last_insert_rowid()' as documented, but instead 'last_insert_row_id()' 
> ---- with an extra underscore character before the 'id'.

The amalgamation source for 3.6.23 has

SQLITE_API sqlite3_int64 sqlite3_last_insert_rowid(sqlite3*);

and

static void last_insert_rowid

I don't know where you got your function from, but I don't think it's SQLite.  
It might be a Ruby library that /calls/ SQLite, in which case the error is with 
whoever wrote the Ruby library.

Simon.
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to