Re:
От | Dave Cramer |
---|---|
Тема | Re: |
Дата | |
Msg-id | D421C922-207D-4F73-BFAC-A61A092A5181@fastcrypt.com обсуждение исходный текст |
Ответ на | Re: (vasylenko@uksatse.org.ua) |
Список | pgsql-jdbc |
On 11-Jan-07, at 1:42 AM, vasylenko@uksatse.org.ua wrote: > > > > Dave and Andre, thank for your responses! > > The JDBC driver needs the Primary Key in Select query to identify > the row. > I was mistaken thinking of doing without it, > > ResultSet makes updates in Row executing the > > java.sql.Connection.prepareStatement("UPDATE holidays SET "g_name" > = ? > WHERE "id" = ?") > and executeUpdate() > > when user makes call ResultSet.updateRow() and "id" - the Primary > Key in > database's table. It's logicaly for me now.... > > The same is going on whe users call ResultSet.insertRow(). > The only question presents, why the JDBCDriver developers want to find > PrimaryKey or oid field inside method "moveToInsertRow()"? > I think it mustn't be JDBCDriver problem. > It is the Postrgre server trouble or developers who use JDBCDriver. Can you explain this more, or send a small test case. There should be no reason to get a primary key simply to move to insert row. We do need the primary key in the dataset, but other than that we shouldn't fail on move to insert row ? Dave > > > I'm going to do in way Andre has recommended and use id field in > SELECT > query as Dave has advised. > > Thank! > > > ---------------------------(end of > broadcast)--------------------------- > TIP 1: if posting/reading through Usenet, please send an appropriate > subscribe-nomail command to majordomo@postgresql.org so that > your > message can get through to the mailing list cleanly
В списке pgsql-jdbc по дате отправления: