Jump to content

java sqlite driver issue

Hello,

 

I need help with this java database issue. The program can't seem to locate the driver. I got the driver and code I'm testing from this site: https://bitbucket.org/xerial/sqlite-jdbc The only difference with class name but everything else is the same. I attached a picture of the problem.

 

Error:

Exception in thread "main" java.lang.Error: Unresolved compilation problem:

    at dbtest.DBTest.main(DBTest.java:9)

 

Line 9 is the highlighted code in the attached screenshot.

 

sqljava.png

My system: CPU: Intel i5 6500; Mobo: H110M-k; GPU: Nvidia GT 730; Memory: 16 GB; HDD: 2x 1TB HDD;

Link to comment
Share on other sites

Link to post
Share on other sites

Have you tried running a clean and build since you downloaded the project?

Link to comment
Share on other sites

Link to post
Share on other sites

Above the console, click the problems tab and post what's in there.

1474412270.2748842

Link to comment
Share on other sites

Link to post
Share on other sites

11 hours ago, vibeit said:

Hello,

 

I need help with this java database issue. The program can't seem to locate the driver. I got the driver and code I'm testing from this site: https://bitbucket.org/xerial/sqlite-jdbc The only difference with class name but everything else is the same. I attached a picture of the problem.

 

Error:

Exception in thread "main" java.lang.Error: Unresolved compilation problem:

    at dbtest.DBTest.main(DBTest.java:9)

 

Line 9 is the highlighted code in the attached screenshot.

 

sqljava.png

dont do an executeUpdate, do a straight execute. also, it should probably be "insert into person(id,name) values (1, 'leo')" same for the next line

Link to comment
Share on other sites

Link to post
Share on other sites

1 hour ago, rockking1379 said:

also, it should probably be "insert into person(id,name) values (1, 'leo')" same for the next line

Don't need to give column names if your're inserting for all columns.

1474412270.2748842

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×