|
|
Sponsor |
Re: @@IDENTITY (Was: Access - ODBC - serial problem): msg#00082db.postgresql.odbc
> -----Original Message----- > From: Philippe Lang [mailto:philippe.lang@xxxxxxxxxxxxxx] > Sent: 10 April 2004 09:59 > To: pgsql-odbc@xxxxxxxxxxxxxx > Cc: scott.marlowe > Subject: Re: [ODBC] @@IDENTITY (Was: Access - ODBC - serial problem) > > > For reasons unfathomable to modern man, Microsoft chose > @@IDENTITY to mean, not the current user, as I or you or any > sane person would expect, but to hold the incremented value of > an autoincrementing column fed by an insert. > Another triumph in orthogonally named things from Microsoft. Ahh, that was some good thinking on their part, though it does sorta make sense. > - After an insert, Postgresql ODBC driver reads the data > based on the values that have been inserted. There are cases > were these values already existed in the table before the > insert, and so the autoincrement fetched may not be correct. It does? I wasn't aware of that. I assume you mean when using cursors (which I never use) as it doesn't following a regular insert statement. > Is there anything that can be done at the driver level? Standard answer: The best method would be to do a "SELECT currval('seq_name');" when required on the relevant sequence. Regards, Dave. ---------------------------(end of broadcast)--------------------------- TIP 4: Don't 'kill -9' the postmaster
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Re: ODBC driver further developments?, Bruce Momjian |
|---|---|
| Next by Date: | Re: fixes for psqlodbc-07.03.200, patch, Dave Page |
| Previous by Thread: | LOG: unexpected EOF on client connection, Chris Gamache |
| Next by Thread: | Re: [patch] CodeGuard fix, Bruce Momjian |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
Free MagazinesCisco NewsReceive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business. subscribe Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field. subscribe The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business. subscribe Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company. subscribe Total Telecom Total Telecom is "The Economist of the communications industry". subscribe |
Home | sitemap
| advertise | OSDir is
an inevitable website.
|