Skip site navigation (1) Skip section navigation (2)

NullPointerException when calling ResultSet.absolute(int)

From: Clemens Eisserer <linuxhippy(at)gmail(dot)com>
To: pgsql-jdbc(at)postgresql(dot)org
Subject: NullPointerException when calling ResultSet.absolute(int)
Date: 2005-08-28 17:01:53
Message-ID: 194f625505082810015456609c@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-jdbc
Hi there!

I've installed PostgreSQL-7.4 on my system and I am really impressed
about the features and stability PostgreSQL provides. Its an excellent
piece of software!

However I've written a Swing-Table which displays data directly from a
ResultSet, and this works great if I select all rows, but when doing a
more specific search I get a NullPointerException:


Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
	at org.postgresql.jdbc2.AbstractJdbc2ResultSet.absolute(AbstractJdbc2ResultSet.java:184)
	at CATableModel.getValueAt(CATableModel.java:88)
	at javax.swing.JTable.getValueAt(JTable.java:1852)

Any ideas what could be the cause?

Thank you in advance, lg Clemens

btw. is there a more intelligent way to find out how many lines have
been selected than starting two queries where the one query just
queries the row-count?
I did not find any better solution, but for complex queries this is
really inefficient :-(

Responses

pgsql-jdbc by date

Next:From: Clemens EissererDate: 2005-08-28 17:30:54
Subject: Re: NullPointerException when calling ResultSet.absolute(int)
Previous:From: David GagnonDate: 2005-08-28 14:14:03
Subject: Re: implementing asynchronous notifications PLEASE CONFIRM MY

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group