aspose file tools*
The moose likes JDBC and the fly likes com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException" Watch "com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException" New topic
Author

com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException

Rahul Bhalla
Greenhorn

Joined: Jan 28, 2012
Posts: 17
Hello rancher
In my application after getting the statement object i try to execute give comand

but on server i found given exception
com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Table 'taskproject.adminregisteration' doesn't exist
please also tell if table is empty then what happen after executing above command
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18675
    
    8

Rahul Bhalla wrote:Hello rancher
In my application after getting the statement object i try to execute give comand

but on server i found given exception
com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Table 'taskproject.adminregisteration' doesn't exist


Then the conclusion you should draw from that is that... the table doesn't exist. Really. Programmers try to write code which is useful, so they try to write code which produces error messages which explain the problem. You should assume that is the case when you see an error message.

(My guess is that its name is "adminregistration" instead of "adminregisteration".)

please also tell if table is empty then what happen after executing above command


If the table exists, and is empty, then what happens is that control proceeds to the next line of code after that one. No exceptions are thrown for queries which do not return any rows.
James Boswell
Bartender

Joined: Nov 09, 2011
Posts: 1030
    
    5

Does the table specified in the exception message exist? Perhaps the name of the table in the DB and the application code don't match up?
James Boswell
Bartender

Joined: Nov 09, 2011
Posts: 1030
    
    5

Another thing to check is if your connection is set to use the 'taskproject' database schema by default.
Rahul Bhalla
Greenhorn

Joined: Jan 28, 2012
Posts: 17
you are right, there is a spelling mistake now my program runs
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException