GORM - database first?

W

wicket

Guest
Hello,
I'm going to prototype my database (draw diagrams and relations) in tool like MySql Workbench or SQL Power Architect. Then, create my tables on SQL server and use this database in my GRails application.

Entity Framework in .NET provides two approaches to the problem: code or database first. On the other hand GORM seems to be code-first oriented.

Should I switch to code-first approach or use grails reverse engineering plugins? I'm going to create application from scratch.

Regards,
 
I

ibotirama

Guest
In Grails, I advise worry primarily with domain objects, after you can tunnig your database model, becouse te focus is in a perfect object orientation with a low coupling and high cohesion
 

woodmawa

New member
if creating from scratch id let gorm generate the tables and use the db migration to handle changes over the lifetime of project. if you do table first - you always have to track change in DB and then do the code as well and ensure you are keeping it all in step

work either way - but for new app - i'd let gorm create the tables (basically cos I write code normally - and i'm not a SQL head)
 
Top