We should use the [Dollar Quoting Value] option in create function in editor and create function templates. We should also look into changing the default value of the option to $$ instead of single quote so we don't need to escape single quotes withing the method body.
|
146 KB
|
523 KB
|
180 KB
|
86 KB
The default value has been changed to use $$. Create new function and create function in editor will also use the [Dollar Quoting Value] to script new functions.
Committed revision: 52705
The following fixes have been made in Commit Revision 52718 & 52720:
(a) If the dollar quoting value is not equal to a single quote, any character string of \ within the body of the function/procedure will no longer be escaped. ** This modifications has been ported to version 17 **
(b) Dollar Quoting Value default is now set to $$ when no value is provided.
(c) Extraction of parameters and there info have had modifications made in order to handle creating parameters names with single quotes in them or escaped double quotes in them. This was required as postgresql stores the parameter names differently in proargnames and arginfo catalog columns.
The following fixes have been made in Commit Revision 52718 & 52720:
(a) If the dollar quoting value is not equal to a single quote, any character string of \ within the body of the function/procedure will no longer be escaped. ** This modifications has been ported to version 17 **
(b) Dollar Quoting Value default is now set to $$ when no value is provided.
(c) Extraction of parameters and there info have had modifications made in order to handle creating parameters names with single quotes in them or escaped double quotes in them. This was required as postgresql stores the parameter names differently in proargnames and arginfo catalog columns.
Verified in ADS-18.0.0.Preview-36. Refer updated screenshot 'Updated_14931.png'
Reopened for ADS-17.0.11-6 version : Dollar [$$] quoting not displayed for created function through Edit in Function option and script object to window as option . Refer screenshot 'Updated_14931_V17_behaviour.png'
Verified in ADS-18.0.0.Preview-36. Refer updated screenshot 'Updated_14931.png'
Reopened for ADS-17.0.11-6 version : Dollar [$$] quoting not displayed for created function through Edit in Function option and script object to window as option . Refer screenshot 'Updated_14931_V17_behaviour.png'
I have tested with 17 and it appears to be working as designed. attaching screenshot. Please make sure that in 17 your option is correctly set. In 18 we have changed the default to $$ but in 17 we did not change the default. So you most specify the dollar option if you don't wish to use the single quote as the default in 17. attaching screen shot of 17 working correctly.
I have tested with 17 and it appears to be working as designed. attaching screenshot. Please make sure that in 17 your option is correctly set. In 18 we have changed the default to $$ but in 17 we did not change the default. So you most specify the dollar option if you don't wish to use the single quote as the default in 17. attaching screen shot of 17 working correctly.
Verified in ADS-17.0.-11.6.Refer updated screenshot 'Updated_14931_V17.png'
Verified in ADS-17.0.-11.6.Refer updated screenshot 'Updated_14931_V17.png'
Issue #14931 |
Closed |
Fixed |
Resolved |
Completion |
No due date |
Fixed Build preview-14, v18.0.0-preview-13, v17.0.11-4 |
No time estimate |
1 issue link |
relates to #14936
Issue #14936PostgreSQL -> Function -> If parameter names contain single quote in them edit in editor fails to compile function |
The default value has been changed to use $$. Create new function and create function in editor will also use the [Dollar Quoting Value] to script new functions.
Committed revision: 52705