Re: JDBC and fetching the OID of an insert

Поиск
Список
Период
Сортировка
От Dave Cramer
Тема Re: JDBC and fetching the OID of an insert
Дата
Msg-id 1032359034.26943.67.camel@inspiron.cramers
обсуждение исходный текст
Ответ на Re: JDBC and fetching the OID of an insert  ("Michael Paesold" <mpaesold@gmx.at>)
Список pgsql-jdbc
Michael,

Well, the method in the driver will work for you.

dave
On Wed, 2002-09-18 at 10:21, Michael Paesold wrote:
> Dave Cramer wrote:
>
> > There is or was actually a method in the driver ResultSet.getLastOID
> > which allowed you to do this.You will have to cast the resultset into a
> > AbstractJdbc(x)ResultSet, where x is the version; but Daryl's way is
> > much better since oid's can wrap, and there is a possiblity that they
> > don't exist ( you can turn them off in postgres).
> >
> > Dave
>
> I don't really care that oid's can wrap. I don't need them as sequences.
> Instead I was just looking for the easiest way to get a reference to the row
> I just inserted.
>
> So my considerations about getGeneratedKeys() would only work if oid's are
> not turned off -- very bad for a driver...
>
> Michael
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
>
>



В списке pgsql-jdbc по дате отправления:

Предыдущее
От: "Michael Paesold"
Дата:
Сообщение: Re: JDBC and fetching the OID of an insert
Следующее
От: Kevin Schmidt
Дата:
Сообщение: setBoolean with BIT column