Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

SQL statements Error in java code using Intellij and DB Navigator

I am using mysql in intellij IDE? I have DB Navigator installed and tested my connection successfully. I have used mysql workbench to successfully create a database and am able to see the database(filecatalog) on IDE as shown in the image below

However, when I write SQL statements in my code it gets highlighted(underlined in red) as an error and intellisense says "Unrecognized statement" . Same case for both CREATE table and INSERT statements as shown in the image. Any ideas what I could be missing? enter image description here

like image 967
crakama Avatar asked Sep 03 '26 14:09

crakama


1 Answers

Eventually I have solved it. The problem wasn't with my code but rather with the version of IDE that I was using (Community Version), it wasn't working well with the DB Navigator plugin that I downloaded,at least for my case.

So I downloaded Intellij Ultimate version which includes Database Tools and SQL support, configured as shown below and the errors disappeared. enter image description here

enter image description here

like image 50
crakama Avatar answered Sep 05 '26 04:09

crakama