This week's book giveaways are in the Refactoring and Agile forums.
We're giving away four copies each of Re-engineering Legacy Software and Docker in Action and have the authors on-line!
See this thread and this one for details.
Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Agile forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Getting a SQL Exception ?

 
lakmal padmakumara
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator


Hey Friends , I'm getting an error which is mentioned below when i run my programme !!



I know something wrong with my sql query .But Cannot figure it out !!!I have attached my sql database also .It does not contain any data .Only a Table .I have been checking this for nearly 7 hours using tutorials and other internet stuff.If you can please give me a help !!

My SQL Db is here
http://download734.mediafire.com/d9ccljmteydg/tnhixyhlzz2/localhost.sql
 
Vijitha Kumara
Bartender
Posts: 3913
9
Chrome Fedora Hibernate
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As the exception says error is in your SQL:

After the "VALUES" clause you should have only one (opening) round bracket and one at the end (closing round bracket). It should not have any in between.
 
lakmal padmakumara
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey Friends , I found it !!! From Java Ranch ,

The insert into code should be changed as



 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic