Re: Last inserted id
От | Simeó Reig |
---|---|
Тема | Re: Last inserted id |
Дата | |
Msg-id | Pine.LNX.4.10.10111121424020.4974-100000@chico.machine.net обсуждение исходный текст |
Ответ на | Re: Last inserted id (Jean-Michel POURE <jm.poure@freesurf.fr>) |
Список | pgsql-odbc |
On Mon, 12 Nov 2001, Jean-Michel POURE wrote: > At 09:55 12/11/01 +0000, you wrote: > >'Cos that's not safe either - you might get multiple rows inserted at the > >same time - unlikely, but certainly possible. > > In most cases a simple timestamp is enough because you add some other > parameter to you query (ex:company name, or whatever field you inserted). > For example, if you insert values with First_name=Dave, Second_name=Page, > Timestamp=current time and query the resulting row, there is *very little* > chance to get rows from other users. > > I guess this is the recommended way (see Access howto). Yes, but the query for search the row is more expensive than select from an id that is normally indexed. I have making tests and 'option A' seems be the best. Thanks Simeo Reig
В списке pgsql-odbc по дате отправления: