Hi Carsten,

you are right - I didn't go through the entire patch and I missed that.

I would like to hear the opinions (if any) of other people on the list - do they find the feature useful or not?

regards,
bogdan

Carsten Bock wrote:

Hi Bogdan,

Actually i did add a capability flag in db_cap.h and the API will set the flag, if the database-module (e. g. the mySQL module) supports it. After all, i did not add it to "DB_CAP_ALL", so all existing modules should still work even with databases that does not support this function (e. g. the usrloc-module). A module, requiring this functionality, can check in the capabilities...
Actually, i wanted to keep all existing modules working.... ;-)

Carsten

Bogdan-Andrei Iancu schrieb:

Hi Carsten,

no, the patch was no lost :). I was trying to see if a similar function exists for postgres. Any change in the DB API is translated in updating *all* module implementing it - mysql, postgres, flatstore, dbtext, unixodbc.

Maybe a better approach is to add a new capability flag for this feature; if supported, the DB module will advertise this flag; see db/db_cap.h

regards,
bogdan

Carsten Bock wrote:

Hi everybody,

I am not really sure, if anyone excepts me needs this functionality, but however: I extended the OpenSER-Database-API and the mySQL-Module with an "last_inserted_id" method. This method returns the last inserted ID of an INSERT-statement, in case the table has an auto-increment field. I did only implement this functionality in the mySQL module; i took a look in the PostgreSQL-Docs and i did not find an according functionality in the postgres-C-API.... (to be honest: since we do not use postgres in this project, i did not spend too much time searching...)
What do you think?

Kind regards,
Carsten







_______________________________________________
Devel mailing list
[email protected]
http://openser.org/cgi-bin/mailman/listinfo/devel

Reply via email to