I am using Java hibernate in my application with MySQL 8. I have a table “Groups” for which I created entity in my entity. Now problem is that whenever I am trying to execute any query related to this table, application is throwing error.
String query = "FROM Groups AS g WHERE g.Id = ?0";
List<Groups> groups = (List<Groups>) find(query, Id);
Error
java.sql.SQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use
3