SQL statement asks for parameters and won't run in Datagrip but will run in other SQL clients

Hi, 

I'm trying to use the syntax fieldname::datatype in order to cast a field as a new datatype, in this case casting it to text and then to date.  This doesn't seem to work in datagrip and when I run it, it asks for parameters.  However, when I copy the same script into say DBeaver, the script is able to run perfectly.  How do I go about fixing this? For example:

SELECT ui.InvDate::text::date
FROM tablename ui

Thanks!

6 comments
Comment actions Permalink

Hi,

Change user parameters in settings as you like:


Also, could you specify DataGrip version you use?

Thank you.

0
Comment actions Permalink

I tried to turn off all of the user parameters, but it's still asking for them when I run the script.

0
Comment actions Permalink

Can I get a follow up response? 

0
Comment actions Permalink

Me too - I have this exact same problem - would love to get some follow up on it. 

 

0
Comment actions Permalink

@ Alamendola Hi,

You need to enable parameter injecting by checking checkboxes above Parameter Patterns:

Thank you.

-1

Please sign in to leave a comment.