SQL User parameters %(name)s not prompted

have  very simple query

WHERE (%(acct_name)s is NULL or a.short_name = %(acct_name)s)

I have setup a User Parameter like so


enabled for all languages, and both checkboxes checked; however when trying to run this query in Console - not getting prompted for the parameter value (i.e. acct_name)

Comment actions Permalink

Also tried the following - still no luck

Comment actions Permalink

if i place the query into a separate foo.sql file, then I do get prompted for parameter.

Comment actions Permalink

Hello Yelena,

It works for me, see the screenshots:

What PyCharm version are you using? Have you configured SQL dialect for the file? Do you see error marks in sql injected string?

Make also sure that Always review parameters before execution settings is enabled.

Comment actions Permalink

Hi Yelena,

Did you manage to solve this? I'm seeing the same thing right now too just after upgrading to PyCharm 2016.3


Please sign in to leave a comment.