Community technical support mailing list was retired 2010 and replaced with a professional technical support team. For assistance please contact: Pre-sales Technical support via email to email@example.com.
Tony Hoyle wrote: > David Somers wrote: >> Tony, >> >> cvsapi/db/postgres/PostgresConnection is broken. >> ::ExecuteAndReturnIdentity makes use of "RETURNING" which is an ORACLE >> ::(and >> SQLITE?)-specific option. > > According to the to a site I read that's the recommended way of getting > the id > back on postgres.... maybe only works on the latest one. Not on 8.1.4 which is the latest and greatest. I saw a patch that implemented it about a year ago but I don't know the status of it. > Can't see any other way of doing it that's safe (using two statements is > not safe as you may have many clients inserting). Isn't the SessionId unique and only inserted once? So: INSERT INTO SessionLog ( ... SessionId ...) Value ( ... 'XXX' ... ) SELECT id FROM SessionLog WHERE SessionId='XXX' BTW, I do find your audit schema a bit odd in that sessionid in sessionlog is not used throughout the other tables, but instead you seem to refer to it indirectly by the id of sessionlog. (Having sessionid meaning different things in different tables is also a tad confusing.) David