Disable auto quotes around table and column names

Using Autocomplete within DataGrip will wrap a table or column name with quotes. Here's an example:

SELECT * FROM "Table"

The issue is that running these statements results in a SQL syntax error. I have been manually typing everything in, effectively rendering the autocomplete useless.

How can I disable the auto-quotation feature?

Thanks!

15 comments
Comment actions Permalink

Hi,

Could you specify driver, dialect and database you're working with?

Thank you

0
Comment actions Permalink

I have this same issue, working with MS SQL Server.

Heres an example, for instance

select * from "app_event_type" where "event_type"='foo'

 

0
Comment actions Permalink

This is still happening with latest DG 2017.1.5 MSSqlServer

0
Comment actions Permalink

Hi,

Do you invoke completion in a file or in a console? If you invoke completion in a file be sure to define SQL dialect correctly for the file.

Also, could you attach a screenshot of your Editor -> Code Style -> SQL settings, e.g.:

Currently, I can't reproduce your problem.

Thank you.

 

0
Comment actions Permalink

I have the same problem. It happens with any dialect and none of the SQL dialect quoting options seem to have any effect. I'm using 2017.2.2. It seems to happen on all column names which are in mixed case (e.g. msgDate).

0
Comment actions Permalink

Same problem here with datagrip or intellij

When querying all is ok:

When double tapping a table or using autocomplete though:

When 

0
Comment actions Permalink

I'm having this issue in datagrip 2017.3 and 2017.3.1 with dialect set to oracle. 

All autocompleted table and column names have quotes around them making all sql invalid. 

1
Comment actions Permalink

@Zachary Goldstein Hi,

Could you provide sample DDL and query you use?

Also, it'll be useful to see your data source and driver settings. 

Thank you.

0
Comment actions Permalink

I made a new table  to recreate (note that all of our existing tables have this problem regardless of their structure):

create table tmp_zack (
case_type number(12)
) tablespace our_space

*Note that I issued the create statement outside of datagrip. I found that if I created the table from within a datagrip console then datagrip _did_ autocomplete it correctly (at least during that session)*

Back in datagrip in the database tool, I did "forget cached schemas" for my database connection then synchronized the schema.

 
Any query works:
e.g. select * from tmp_zack.

All auto completes on tmp_zack whether qualified the schema name or not add the quote marks around tmp_zack.


In the meantime I have rolled back to datagrip 2017.2.3 and it is working fine.


What pages do you want to see from the database and drivers settings? Do you have an email I can send logs to (and how do you want those settings dumped from datagrip?)

My Database connection is using the oracle driver.
This is the linked driver page:

0
Comment actions Permalink

Hi,

There is an issue https://youtrack.jetbrains.com/issue/DBE-5531 you can track and vote for.

It'll be helpful to get test connection details and a screenshot of your database tree.

Thank you.

0
Comment actions Permalink

I am also having this problem, but only with my Editor->Code Style->SQL-->General->Word Case->Quoted Identifiers set to "To lower".

Changing the next option (Identifier quotation) does not have any effect.

0
Comment actions Permalink

@KPowers Hi,


>> It'll be helpful to get test connection details and a screenshot of your database tree.

It could be that your database base casing is "To Lower"

Thank you.

0
Comment actions Permalink

Additional details in case they are useful:

DataGrip 2017.3.2
Build #DB-173.3942.44, built on December 15, 2017
Licensed to <snip>
JRE: 1.8.0_152-release-1024-b8 amd64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
Linux 4.4.0-101-generic

 

Test connection details:

Database: Oracle (ver. Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production With the Partitioning, OLAP, Advanced Analytics and Real Application Testing options) Identifier case sensitivity: upper (plain), exact (delimited) Driver (JDBC4.0): Oracle JDBC driver (ver. 12.1.0.2.0)

 

Database tree screenshot (is this what you mean by database tree?):

Note: in this screenshot I have changed my formatter settings to avoid the bug.

0
Comment actions Permalink

This issue is resolved in version 2017.3.4.  Thank you!

1

Please sign in to leave a comment.