-
Notifications
You must be signed in to change notification settings - Fork 91
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
SQL::Translator::Utils::parse_list_arg does not allow indexes on expressions with more than one argument #83
Comments
mrmuskrat
changed the title
PostgreSQL parser does not allow indexes on expressions with more than one argument
PostgreSQL parser (?) does not allow indexes on expressions with more than one argument
Dec 8, 2016
It looks like this is actually the behavior of SQL::Translator::Utils::parse_list_arg (called by SQL::Translator::Schema::Index->new when it processes the fields argument). It splits strings on commas without regard for the contents. |
I have a fix for it but it's a bit verbose. It uses Regexp::Common::balanced to only do the comma split on portions of strings that do not contain balanced parentheses.
|
mrmuskrat
changed the title
PostgreSQL parser (?) does not allow indexes on expressions with more than one argument
SQL::Translator::Utils::parse_list_arg does not allow indexes on expressions with more than one argument
Dec 9, 2016
Closed
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You cannot add an index on an expression (aka a functional index) using a function that more than one argument like shown in the following test addition:
The text was updated successfully, but these errors were encountered: