Is it possible to detect unused columns in my database using Hibernate?

I have a MySQL database with one hundred or more tables that is used with Hibernate, and I came across several columns that are no longer in use. That is, they still exist in the database, but not in the model. Is it possible to detect these columns in a database that are no longer in use?

+3
source share
1 answer

In sleep mode, there is no circuit comparison tool.

I would recommend using something like Hibernate Tools SchemaExport to create DDL from your Hibernate model and then using mysqldump to get the target database schema. Then use the schematic comparison tool of your choice to find the differences.

+3
source

All Articles