Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

Unable to register driver (jdbc.sybase.jdbc.SybDriver)

3 posts in JDBC Connect (product renamed to JConnect) Last posting was on 1997-04-29 22:12:48.0Z
Pawan Desai Posted on 1997-04-23 18:21:47.0Z
Message-ID: <335E533B.229D@caribsurf.com>
Date: Wed, 23 Apr 1997 11:21:47 -0700
From: Pawan Desai <pdesai@geocities.com>
Reply-To: pdesai@geocities.com
Organization: TTSL
X-Mailer: Mozilla 3.0 (WinNT; I)
MIME-Version: 1.0
Subject: Unable to register driver (jdbc.sybase.jdbc.SybDriver)
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Newsgroups: sybase.public.jdbcconnect
Lines: 25
Path: forums-1-dub!forums-master.sybase.com!forums.powersoft.com
Xref: forums-1-dub sybase.public.jdbcconnect:945
Article PK: 252696

Hello Friends

I am trying to Register the jdbc driver from jconnect. I have set the
classpath properly to the jconnect classes directory. I want to use
JDK1.02, So I want to register jdbc.sybase.jdbc.SybDriver. The following
is the code for that :

// REGISTER DRIVER
try
{
Driver d =
(Driver)Class.forName("jdbc.sybase.jdbc.SybDriver").newInstance();
}
catch (Exception e)
{
System.out.println(e)
}

But this gives me an error as follows :

registerDriver() Failed:
java.lang.ClassCastException: jdbc.sybase.jdbc.SybDriver

But if I try to register the JDK1.1 version driver
com.sybase.jdbc.SybDriver. It gets installed correctly. Following is the
code for that.

try
{
Driver d =
(Driver)Class.forName("com.sybase.jdbc.SybDriver").newInstance();
}
catch (Exception e)
{
System.out.println(e)
}

I want to ask whether I can force jconnect to use
jdbc.sybase.jdbc.Sybdriver.

Thanx & Regards

Regards
pawan.desai


David Clegg Posted on 1997-04-28 17:37:39.0Z
Message-ID: <3364E063.15A918CF@sybase.com>
Date: Mon, 28 Apr 1997 10:37:39 -0700
From: David Clegg <davec@sybase.com>
X-Mailer: Mozilla 2.01 (X11; I; Linux 1.2.13 i586)
MIME-Version: 1.0
To: pdesai@geocities.com
Subject: Re: Unable to register driver (jdbc.sybase.jdbc.SybDriver)
References: <335E533B.229D@caribsurf.com>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Newsgroups: sybase.public.jdbcconnect
Lines: 32
Path: forums-1-dub!forums-master.sybase.com!forums.powersoft.com
Xref: forums-1-dub sybase.public.jdbcconnect:913
Article PK: 252665

I suspect that you have not changed the import statements in your
application - you are importing java.sql.Driver instead of
jdbc.sql.Driver, thus the ClassCastException

dave

>
> Hello Friends
>
> I am trying to Register the jdbc driver from jconnect. I have set the
> classpath properly to the jconnect classes directory. I want to use
> JDK1.02, So I want to register jdbc.sybase.jdbc.SybDriver. The following
> is the code for that :
>
> // REGISTER DRIVER
> try
> {
> Driver d =
> (Driver)Class.forName("jdbc.sybase.jdbc.SybDriver").newInstance();
> }
> catch (Exception e)
> {
> System.out.println(e)
> }
>
> But this gives me an error as follows :
>
> registerDriver() Failed:
> java.lang.ClassCastException: jdbc.sybase.jdbc.SybDriver
>
> But if I try to register the JDK1.1 version driver
> com.sybase.jdbc.SybDriver. It gets installed correctly. Following is the
> code for that.
>
> try
> {
> Driver d =
> (Driver)Class.forName("com.sybase.jdbc.SybDriver").newInstance();
> }
> catch (Exception e)
> {
> System.out.println(e)
> }
>
> I want to ask whether I can force jconnect to use
> jdbc.sybase.jdbc.Sybdriver.
>
> Thanx & Regards
>
> Regards
> pawan.desai


Pawan Desai Posted on 1997-04-29 22:12:48.0Z
Message-ID: <33667260.70E4@caribsurf.com>
Date: Tue, 29 Apr 1997 15:12:48 -0700
From: Pawan Desai <pdesai@caribsurf.com>
Reply-To: pdesai@caribsurf.com
Organization: TTSL
X-Mailer: Mozilla 3.0 (WinNT; I)
MIME-Version: 1.0
Subject: Re: Unable to register driver (jdbc.sybase.jdbc.SybDriver)
References: <335E533B.229D@caribsurf.com> <3364E063.15A918CF@sybase.com>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Newsgroups: sybase.public.jdbcconnect
Lines: 38
Path: forums-1-dub!forums-master.sybase.com!forums.powersoft.com
Xref: forums-1-dub sybase.public.jdbcconnect:901
Article PK: 252653

Thanx Dave..Basically I had messed up my classpath. But now my applet is
up and running

Regards
pawan.desai

David Clegg wrote:
>
> I suspect that you have not changed the import statements in your
> application - you are importing java.sql.Driver instead of
> jdbc.sql.Driver, thus the ClassCastException
>
> dave
> >
> > Hello Friends
> >
> > I am trying to Register the jdbc driver from jconnect. I have set the
> > classpath properly to the jconnect classes directory. I want to use
> > JDK1.02, So I want to register jdbc.sybase.jdbc.SybDriver. The following
> > is the code for that :
> >
> > // REGISTER DRIVER
> > try
> > {
> > Driver d =
> > (Driver)Class.forName("jdbc.sybase.jdbc.SybDriver").newInstance();
> > }
> > catch (Exception e)
> > {
> > System.out.println(e)
> > }
> >
> > But this gives me an error as follows :
> >
> > registerDriver() Failed:
> > java.lang.ClassCastException: jdbc.sybase.jdbc.SybDriver
> >
> > But if I try to register the JDK1.1 version driver
> > com.sybase.jdbc.SybDriver. It gets installed correctly. Following is the
> > code for that.
> >
> > try
> > {
> > Driver d =
> > (Driver)Class.forName("com.sybase.jdbc.SybDriver").newInstance();
> > }
> > catch (Exception e)
> > {
> > System.out.println(e)
> > }
> >
> > I want to ask whether I can force jconnect to use
> > jdbc.sybase.jdbc.Sybdriver.
> >
> > Thanx & Regards
> >
> > Regards
> > pawan.desai