No auto completion of synonyms and synonyms not recognized

I'm not getting auto completion of synonyms and synonyms are not recognized ("unable to resolve table")

In 2017.2, "resolve unqualified references" option isn't available.  I can query the table using the synonym.  It doesn't help to qualify with the schema first. 

I tried Preferences/Database/SQL Resolution Scopes - added my sql file and chose the schema from the drop down.  Nothing seemed to happen.  When I came back to this screen, the mapping had disappeared.

When I try to generate DDL of the synonym to the console, I get nothing.

Database is DB2.

10 comments
Comment actions Permalink

Hi,

I created an issue https://youtrack.jetbrains.com/issue/DBE-5401 you can track and vote for.

Thank you.

0
Comment actions Permalink

Does it suppose to work? An issue is closed as fixed.

 

0
Comment actions Permalink

Zhenya Shaggyr,

Yes, It should work.
Do you experience problems? Could you provide a sample to reproduce the issue?

0
Comment actions Permalink

Seem like the problem is in transporting the synonyms scripts. That's like they look in data grip and in SSMS :(

0
Comment actions Permalink

Zhenya Shaggyr,

Make sure you select schema where you defined the synonym.

For example

Also, do you work with sql files or with consoles?

 

 

1
Comment actions Permalink

Synonyms and procedures are defined in the same database -> same schema. And they are sql files.

0
Comment actions Permalink

Zhenya Shaggyr,

Have you set up Resolution scopes for your files?

0
Comment actions Permalink

It still not working for me either.  I do have a resolution scope set up for my files.

0
Comment actions Permalink

Jim Orten

What is DataGrip version you running?

0
Comment actions Permalink

Has this issue been solved? I have the same problem. Two MS SQL DB's on the same DB Server (localhost), both DB's in tree and all schemas enabled. Synonyms from DB1 point to tables of DB2

I am running DG version 2020.1.3.

0

Please sign in to leave a comment.