i'm using java5, mySql 4.1 and my driver is mysql-connector-java-3.0.16-ga-bin.jar i'm using eclipse 3.2 too after testing my Jdbc class and get a green, i tried to test it from another computer that is in my home network from mysql admin i granted everything to user root from my son's ip: 192.168.1.102
when i run the jar from my son's pc, i get an SQLException i also tried to run, from dos:telnet pai 3306 but cant connect...(pai is my computer's name) what am i doing wrong? TiA
C:\>java -jar X.jar a come�ar... Exception in thread "main" java.sql.SQLException: com.mysql.jdbc.Driver at bd.JdbcAccess.getConnection(JdbcAccess.java:35) at bd.Filhos.main(Filhos.java:23)
i just opened por 3306 from windows firewall and now telnet prints something, but when running the jar things are the same... btw, i jared everything, driver included
thanks for the sugestion i tried that and a variety of other possible combinations
somehow i've the felling that, from my son's pc, connection is never established
mi idea is that i have my url wrong...
at this moment i have it like this: String url = "jdbc:mysql://192.168.1.101/" + nomeBaseDados + "?user=root&password=abc"; and if i run the class from my pc(where mySql is), it prints ok: