Re: Fwd: Exception in thread "main"

From: Toby Doig <binky(at)flirble(dot)org>
To: Mathew McBride <matt(at)mcbridematt(dot)dhs(dot)org>
Cc: pgsql-jdbc <pgsql-jdbc(at)postgresql(dot)org>
Subject: Re: Fwd: Exception in thread "main"
Date: 2002-10-07 11:33:07
Message-ID: 20021007123138.L70448-100000@plum.flirble.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

> ResultSet rs = st.executeQuery();
> add(name);
> add(va);
> va.setText(rs.getString("va_vairline"));

you need to do an rs.next() first to move rs to the first record.
i'd also test whether sexecuteQuery() did actually return a ResultSet and
not null.

toby

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Felipe Schnack 2002-10-07 13:15:29 OFF-TOPIC: cvs
Previous Message David Wall 2002-10-07 02:57:38 Re: jdbc cursor positioning