Closed josepegea closed 6 years ago
In versions 4.x, when updating the schema.rb file, Rails includes any view in the DB in the list "create_table" statements.
When scenic adds the corresponding "create_view" statements, they fail because of the duplicate names.
This is due to MySQL including views in the output of "show tables" and Rails not filtering them out.
This code patches the schema dumper on old Rails versios to prevent outputting views as if they were tables.
This should fix #2
Looks good! Thanks @josepegea
available in v1.0.1
In versions 4.x, when updating the schema.rb file, Rails includes any view in the DB in the list "create_table" statements.
When scenic adds the corresponding "create_view" statements, they fail because of the duplicate names.
This is due to MySQL including views in the output of "show tables" and Rails not filtering them out.
This code patches the schema dumper on old Rails versios to prevent outputting views as if they were tables.
This should fix #2