I need to generate a grails application from a SQL...
# questions
j
I need to generate a grails application from a SQL DB. Years ago there was a plugin that no longer works that did this reasonably well including creating the domain relations. In Grails 7 and GORM is there some way to generate domain classes from a SQL RDB? Thanks
j
Do you have the plugin name / source?
j
Yes this is the plugin that stopped loading in Grails around version 5 --- reverse-engineer Earlier it was VERY valuable - I could generate the full Grails domain class model in minutes from an existing data model. I used to a lab with this back in Grails 3 that brought a lot of interest in Grails. https://grails-plugins.github.io/grails-db-reverse-engineer/v3/guide/single.html
If this plugin can't work in Grails 7 looking at the next easiest option to generate the domain class model from a SQL RDB Thanks
j
I'm going to take a look at upgrading this to grails 7
👏 1
https://github.com/grails-plugins/grails-db-reverse-engineer/pull/16 upgrades it to grails 7 with hibernate 5 support.
The grails command isn't working, but you can use a sample app to generate the domains. Take a look at
example/mysql
for how it does this. The app will startup, create domains, and shutdown.
j
Thanks I'll give that a try
👍 1