X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (neptune.hub.org [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 0808AD1B4D1 for ; Mon, 22 Dec 2003 23:51:21 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 04545-08 for ; Mon, 22 Dec 2003 19:50:33 -0400 (AST) Received: from anchor-post-34.mail.demon.net (anchor-post-34.mail.demon.net [194.217.242.92]) by svr1.postgresql.org (Postfix) with ESMTP id D4BFAD1B454 for ; Mon, 22 Dec 2003 19:50:30 -0400 (AST) Received: from tmsl-adsl.demon.co.uk ([80.177.114.181] helo=bacon.tmsl.demon.co.uk) by anchor-post-34.mail.demon.net with esmtp (Exim 3.35 #1) id 1AYZon-000M6E-0Y for pgsql-sql@postgresql.org; Mon, 22 Dec 2003 23:50:33 +0000 Date: Mon, 22 Dec 2003 23:50:29 +0000 From: Paul Thomas To: "pgsql-sql @ postgresql . org" Subject: Re: [JDBC] Insert Row to ResultSet problem....java.sql.SQLException: No Primary Keys Message-ID: <20031222235029.A27585@bacon> References: <621ddc9b.0312160724.6c6955db@posting.google.com> Mime-Version: 1.0 Content-Type: text/plain; format=flowed; charset=ISO-8859-1 In-Reply-To: <621ddc9b.0312160724.6c6955db@posting.google.com>; from jasonvanbrackel@speakeasy.net on Tue, Dec 16, 2003 at 15:24:19 +0000 X-Mailer: Balsa 1.2.3 Lines: 28 X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200312/158 X-Sequence-Number: 16324 On 16/12/2003 15:24 Jason L. van Brackel wrote: > [snip] > ..... this is where I get this exception > java.sql.SQLException: No Primary Keys ~~~~~~~~~~~~~~~ > at > org.postgresql.jdbc2.AbstractJdbc2ResultSet.isUpdateable(AbstractJdbc2ResultSet.java:1363) > at > org.postgresql.jdbc2.AbstractJdbc2ResultSet.moveToInsertRow(AbstractJdbc2ResultSet.java:697) > at > com.cimconsultants.EFRMigration.MigrationUtil.main(MigrationUtil.java:62) > [snip] > I'm experienced with Java, but very new to JDBC and PostgreSQL. I'm > using the JDK 1.4, PostgreSQL 7.4, and the binary pg74jdbc3.jar > driver. A total shot in the dark but do you have a primary key on the table? -- Paul Thomas +------------------------------+---------------------------------------------+ | Thomas Micro Systems Limited | Software Solutions for the Smaller Business | | Computer Consultants | http://www.thomas-micro-systems-ltd.co.uk | +------------------------------+---------------------------------------------+