Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation for the Literal class #1749

Open
killua-eu opened this issue Apr 13, 2020 · 0 comments
Open

Documentation for the Literal class #1749

killua-eu opened this issue Apr 13, 2020 · 0 comments
Labels

Comments

@killua-eu
Copy link

@killua-eu killua-eu commented Apr 13, 2020

I looked at https://github.com/cakephp/phinx/blob/master/docs/en/migrations.rst#custom-column-types--default-values but still can't really figure out how to apply this to generate mysql virtual columns. The example sql would be

ALTER TABLE `t_calendar_sources` ADD `c_flag_deleted` boolean GENERATED ALWAYS AS (IF((json_unquote(json_extract(`c_attr`,'$.deleted'))) = 'true', 1, 0)) VIRTUAL NOT NULL;"

Could anyone help out please?

@dereuromark dereuromark added the docs label Jun 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.