Automatically use a default data source in a new .sql file

On phpstorm 2022.1 when i create a new .sql file there is no default session and no data source attached to it. So i need to use 'attach session' every time a new file is created (i use many of them) if i want autocomplete in my source file. On previous version of phpstorm when i created a new file there was always a default data source attached to attached to it.

Is there a way i can use a default data source for a newly created sql file ?


Just to confirm, do you have a proper project/global SQL dialect selected in "Settings/Preferences | Languages & Frameworks | SQL Dialects"?


ok that was it ! For some reason upgrading to the new version removed the project sql dialect for the project. Now it works. Thanks


Please sign in to leave a comment.