aspose file tools*
The moose likes Mac OS and the fly likes JSP connection mysql Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Engineering » Mac OS
Bookmark "JSP connection mysql" Watch "JSP connection mysql" New topic
Author

JSP connection mysql

Lins Alford
Greenhorn

Joined: Nov 18, 2004
Posts: 5
Hi i have been working with jsp and mysql on win for bout a year...now i am migrating to mac osx panther and cant get jsp to connect to a mysql database....

is the connection different? does it use a different driver?? help!!

lins
Simon Brown
sharp shooter, and author
Ranch Hand

Joined: May 10, 2000
Posts: 1913
    
    6
It should all work the same, but you might to provide some more details. Which version of MySQL are you using? Is it running on the Mac or another box? Which JSP container are you running? Do you have the MySQL drivers in the right place? Are you getting any error messages? etc, etc. Hopefully somebody will be able to help you out if you give them some more info.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61421
    
  67

Yup, we'll need more details. JDBC per se has no cross-platform issues that I am aware of. I have web apps running on Windows, Mac OS X, and Linux that all connect, using the exact same JDBC code, to a PostgreSQL database running on Solaris.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Lins Alford
Greenhorn

Joined: Nov 18, 2004
Posts: 5
Hi ok im running mysql 4.1.7 (in usr/Local), Tomcat 4.1 (in Library folder) catalina container,Apache 1.3 on mac os x 10.3.6 panther...

have used mysql connector "mysql-connector-java-3.0.11-stable-bin.jar" in the past with windows but macs so confuse me as they are unix based and i me and unix dont mix!!

so do i need a different connector?? if so where do i put it??

cheers guys for help!!

lins
Lins Alford
Greenhorn

Joined: Nov 18, 2004
Posts: 5
oh and they all are running on the mac box...

lins
Venkatraman Kandaswamy
Ranch Hand

Joined: Jul 07, 2004
Posts: 120
You have the right jar file.

Did you put the mysql jar file in webapps/yourapplication/WEB-INF/lib ?

And what kind of connection error are you getting. Does it say file not found or its some database related connection error? Why dont you post the error for us.


--Venkatraman<br />SCJP 1.4<br /><a href="http://kvrlogs.blogspot.com" target="_blank" rel="nofollow">blog</a>
Lins Alford
Greenhorn

Joined: Nov 18, 2004
Posts: 5
hi there is no server error of such...i just have a simple page that has a routine to connect to a database which doesnt connect....it always fails...

yes did have connector in lib file... am i quoting the correct driver tho?? here is my code to connect:



I just get the failed message when i use safari to view page...

Lins
Venkatraman Kandaswamy
Ranch Hand

Joined: Jul 07, 2004
Posts: 120
Try org.gjt.mm.mysql.Driver
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: JSP connection mysql