B4J Question B4Packager11 and SQL [SOLVED]

Peter Lewis

Active Member
Licensed User
Longtime User
Hi Guys

I am having a problem with the Packager. I installed the SKD 11 as required and I updated to the .47 version of the MySQL connector , also tried the .41 version.

As soon as my program tries to write to the remote database I get this error

errorsql.png


Compile the .jar file in both release and debug modes

If anyone can give some advise , Thank you
 
Last edited:

Daestrum

Expert
Licensed User
Longtime User
The error mentions sqlite driver, are you sure you've told it to use the mysql driver?
 
Upvote 0

Peter Lewis

Active Member
Licensed User
Longtime User
The error mentions sqlite driver, are you sure you've told it to use the mysql driver?
Yes I use both SQLite and MySQL in my program . It works perfectly from the B4j environment but does not work once compiled

#AdditionalJar: sqlite-jdbc-3.7.2
#AdditionalJar: mysql-connector-java-5.1.47-bin

It uses the sqlite first and loads those local files perfectly as can be seen by the Province Log.
and my declarations are

Private Sql2 As SQL
Private sql1 As SQL

This is the error line

Sql2.Initialize2("com.mysql.jdbc.Driver", "jdbc:mysql://162.215.252.76:3306/weed_quiz", "weed_abcd", "password") which again works perfectly thru b4J

I also did a sql1.close before this line just to check and still the same problem
 
Last edited:
Upvote 0

Peter Lewis

Active Member
Licensed User
Longtime User
I found the problem

Due to cable breaks on our WASC cable to connect from South Africa to the World, our ISP was using a different path and different pool addresses. Once I could see that using an old version of the SKD (Shows the IP address problem access denied. I jumped onto MySQL server config and added the new range and now everything works ok.

Thank you for your advise
 
Upvote 0
Top