I have 3 different organizations types and 3 different databases structures: one for each type. When org1 registers I'm creating a new database instance for org1, and when org2 registers I'm creating a new db instance, and same for org3.
Now, how do I run migrations for three different db:structure from my application soon after I create a new database instance for organizations.
I am creating a db instance from application by:
ActiveRecord::Base.connection.execute(sql)
How can I do this? Is there another approach I should be using?