Re: CachedRowSet insertion problem with serial PK

From: Oliver Jowett <oliver(at)opencloud(dot)com>
To: "rcolmegna(at)tiscali(dot)it" <rcolmegna(at)tiscali(dot)it>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: CachedRowSet insertion problem with serial PK
Date: 2006-06-02 15:47:10
Message-ID: 44805D7E.4010706@opencloud.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

rcolmegna(at)tiscali(dot)it wrote:

> CachedRowSet rs;
> ...
> rs.setCommand("select id,info from a WHERE id<?");
> rs.setInt(1, 10);
> ...
> rs.moveToInsertRow();
> rs.setString(2, "zzzz2");
> rs.insertRow();
>
> but I obtain this error:
> "SQLException: Failed on insert row" (generated from the insertRow()
> line).

Can you work out what the real exception thrown by the driver is? It is
hard to diagnose this without knowing what is happening at the low-level
JDBC API level.

-O

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Bakos Sandor 2006-06-02 17:27:42 Re: UTF8
Previous Message rcolmegna@tiscali.it 2006-06-02 14:48:58 CachedRowSet insertion problem with serial PK