• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

unable to run MySQL queries

 
Prashil Wasnik
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I m unable to excute my sql queries in Apache/Tomcat 5.0.27 this queries runs fine in JBOSS 3.2.2
I have the made the jdbc connection as jdbc:sql//localhost:8080/DBName;
is there any difference between the jdbc connection in JBOSS and Tomcat.
please help.
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Since JBoss uses Tomcat as it's servlet/jsp engine, no.

How are you getting the database connection?
 
Prashil Wasnik
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi, as i have told i make the mysql connection using jdbc which uses mysqlconnector.jar. please clear yourself.
 
Masoud Kalali
Author
Ranch Hand
Posts: 531
Java Mac OS X Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Prashil Wasnik:
I m unable to excute my sql queries in Apache/Tomcat 5.0.27 this queries runs fine in JBOSS 3.2.2
I have the made the jdbc connection as jdbc:sql//localhost:8080/DBName;
is there any difference between the jdbc connection in JBOSS and Tomcat.
please help.


in case that you post the log file entry (exceptions ) related to your problem people can help you easier.

also i noticed that you used jdbc:sql//localhost:8080/DBName which is not correct for mysql AFAIR , you should use jdbc:mysql//localhost:8080/DBName instead.
 
Paul Clapham
Sheriff
Posts: 21000
31
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If it works successfully from one machine but not from another machine then there are two immediate possibilities that I can think of:

1. The second machine cannot connect to the server because of some network configuration issue.

2. MySQL's security parameters allow connecting from the first machine but not from the second machine.

It would help if you found the error messages and stack traces describing the actual problem, though. Much more practical than guessing based on "unable to execute".
 
Hassan Schnieder
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

A jboss jndi looks like this as far as I know so far...

"java:/MyJndiName"

and if your running tomcat inside jboss that's what it should look like i'm pretty sure.


regards,
Hassan
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic