No support for MySQL?
![](https://secure.gravatar.com/avatar/c46902e6723e0aa27cf8ff51919a7fff.png?default=mp&rating=pg&size=48)
![](https://secure.gravatar.com/avatar/ce795239ba5dd2384fc2f88ffaff5451.png?default=mp&rating=pg&size=48)
Yeah, officially it's only supporting Postgres. You should be able to convert it, but it might take some work.
MySQL JSON doesn't seem like it is nearly as full featured as Postgres JSON. The casting attribute to array doesn't seem valid for MySQL.
From a quick test:
MySQL JSON doesn't seem like it is nearly as full featured as Postgres JSON. The casting attribute to array doesn't seem valid for MySQL.
From a quick test:
rails db:system:change --to=mysql
I had to modify the migrations to use `json` columns and remove the default values from them.
Also removed the `algorithm: :concurrently` line from a migration.
I also had to disable Plan `features` attribute since this seems like a Postgres only feature: https://api.rubyonrails.org/classes/ActiveRecord/Attributes/ClassMethods.html
To make the features on Plan work, it can probably just be added as a string array column for MySQL instead. We are just storing the array of features in the JSON column for Postgres, but it'd be fine to make this a separate column.
Everything seems to work fine with MySQL after that.
![](https://secure.gravatar.com/avatar/ce795239ba5dd2384fc2f88ffaff5451.png?default=mp&rating=pg&size=48)
I still don't know if I want to officially support MySQL, but it looks like we could add some conditional things to our migrations to handle them nicely depending on the database being used.
https://stackoverflow.com/questions/6178303/database-specific-migration-code?noredirect=1&lq=1
https://stackoverflow.com/questions/6178303/database-specific-migration-code?noredirect=1&lq=1
![](https://secure.gravatar.com/avatar/4d6e43536068d16cdd98c98854b196e2.png?default=mp&rating=pg&size=48)
![](https://secure.gravatar.com/avatar/ce795239ba5dd2384fc2f88ffaff5451.png?default=mp&rating=pg&size=48)
![](https://secure.gravatar.com/avatar/4d6e43536068d16cdd98c98854b196e2.png?default=mp&rating=pg&size=48)
We won't be officially supporting MySQL in Jumpstart Pro, but feel free to email me chris @ gorails.com with the issue you're running into and I'll try to help.
![](https://secure.gravatar.com/avatar/4d6e43536068d16cdd98c98854b196e2.png?default=mp&rating=pg&size=48)
Notifications
You’re not receiving notifications from this thread.