Spring table is not mapped [ from table ]


Your query is not a SQL query. It’s a HQL query. It thus should not use table names, but entity class names (from Student instead of from student).

In above code we using following line. Here “student” is not entity name by default entity name is same as class name so we have use “Student” instead of “student” because of HQL is pick entity name not table name(table name is “student”). So please we care about this concern.
Query query = session.createQuery(“from student”);


Related posts:

This entry was posted in java. Bookmark the permalink.