Title: RE: jdbcTagLib: ResultSetTag does not work with Access DB
You may also be interested to know that, with the line commented out (my quick fix), when the result set is empty one gets an exception + Tomcat crashes (rather the VM crashes) with an access violation:
 
2001-02-05 04:17:26 - Ctx( /sql-examples ): Exception in: R( /sql-examples + /jdbc.jsp + null) - javax.servlet.ServletException: java.sql.SQLException: [Microsoft][ODBC Driver Manager] Invalid cursor state
 
 
Anyway, thanks for your taglib it is really useful. 
I just tried combining it with the Woolox chart library and they work like a charm.  I got some charts displayed in the browser in no time.
When one thinks how much code there is behind and how simple tag libs are to use, this is just amazing
 
Thierry.
-----Original Message-----
From: Delagrange, Morgan [mailto:[EMAIL PROTECTED]]
Sent: Monday, February 05, 2001 4:43 PM
To: '[EMAIL PROTECTED]'
Subject: RE: jdbcTagLib: ResultSetTag does not work with Access DB

Hi all,

Yeah, I use the isBeforeFirst() method to detect if the result set is empty.  Any JDBC 2.0 compliant driver should support that method.  However, in the interest of Access amity, I'll change it.  :)

> -----Original Message-----
> From: Shawn Bayern [mailto:[EMAIL PROTECTED]]
> Sent: Monday, February 05, 2001 3:35 PM
> To: '[EMAIL PROTECTED]'
> Subject: Re: jdbcTagLib: ResultSetTag does not work with Access DB
>
>
> On Mon, 5 Feb 2001, Ciot, Thierry wrote:
>
> > When using an access DB with the odbc bridge I get an
> unsupported feature
> > exception at:
> >
> > ResultSetTag.doStartTag() {
> >     ...
> >     if (_rset.isBeforeFirst() == false) { return SKIP_BODY; }
> >     ...
> > }
> >
> > I commented out that line and got the example working.
> > I suppose the author wanted to check if the result set was empty?
> >
> > Is there any other way to do that such that it is
> compatable with the ODBC
> > bridge?
>
> Since it does a _rset.next() anyway to prepare the ResultSet for later
> use, it'd probably be better to turn
>
>      if (_rset.isBeforeFirst() == false) { return SKIP_BODY; }
>      _rset.next();
>
> into
>
>     if (!_rset.next())
>       return SKIP_BODY;
>
> anyway.  I think you're right about the code trying to
> determine whether
> the ResultSet has any rows; if that's true, then this fix should work.
>
> Shawn
>

Reply via email to