This week's book giveaway is in the JavaFX forum.
We're giving away four copies of Introducing JavaFX 8 Programming and have Herbert Schildt on-line!
See this thread for details.
The moose likes JBoss/WildFly and the fly likes No Suitable driver Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Introducing JavaFX 8 Programming this week in the JavaFX forum!
JavaRanch » Java Forums » Products » JBoss/WildFly
Bookmark "No Suitable driver" Watch "No Suitable driver" New topic

No Suitable driver

rinku singh

Joined: Apr 22, 2003
Posts: 7
hi i am using JBOSS ans syabse as database. i am trying to connect the database throught Entity Bean
================== CODE==========================
try {
Class.forName ("com.sybase.jdbc.SybDriver" ).newInstance();
}catch(ClassNotFoundException ex){
catch(Exception e) {
System.err.println("Error loading driver: " + e);
when i run my client to access the bean deployed on JBOSS. i get error "NO SUITABLE driver". i have modified . jboss.xml file by adding
<mbean code="org.jboss.jdbc.JdbcProvider" name="DefaultDomain:service=JdbcProvider">
<attribute name="Drivers">com.sybase.jdbc.SybDriver</attribute>
as my default driver and add the jDTS.jar in the lib
ext. i donot know understand why i am getting this error and how to remove it. pls help
Juanjo Bazan
Ranch Hand

Joined: Feb 04, 2002
Posts: 231
Make sure the jar file containing the driver is in the classpath.
rinku singh

Joined: Apr 22, 2003
Posts: 7
i have set the classptah and my sample java connection program is running . i am able to log into database. but when i am using the same thing in a EJB and deploying the bean on JBoss and trying to get access to Data base . i am having problem loading driver.
I have alredy set the jboss.jcml
<mbean code="org.jboss.jdbc.JdbcProvider" name="DefaultDomain:service=JdbcProvider">
<attribute name="Drivers">org.hsqldb.jdbcDriver,com.sybase.jdbc.SybDriver</attribute>
=== file
put the jDTS.jar in lb\ext of JBoss
but stil getting the problem.
Any suggestion please
I agree. Here's the link:
subject: No Suitable driver
jQuery in Action, 3rd edition