Connection Issue with Oracle Tools for Visual Studio Code — oracle-tech

    Forum Stats

  • 3,715,956 Users
  • 2,242,917 Discussions
  • 7,845,700 Comments

Discussions

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Connection Issue with Oracle Tools for Visual Studio Code

James Brockman
James Brockman Member Posts: 7 Red Ribbon

This issue falls under the Visual Studio Code extensions for Oracle, version 19.3.1:  I am connected to a database server in the Data Explorer.  I open a .SQL file in another tab, and I hit F1 to connect, going through the steps to select the connection used previously.  I select the same connection the Database Explorer window is using, which was created from a TNS entry.  So far, so good.   I hit Ctrl+R to run the entire script and I get an immediate fail with this error message...

Error: Specified URI '{0}' does not have existing connection

Error: Script execution Cancelled

I can go back to the Explorer Window, and it's still working.  I verified that by right-clicking on a table and selecting 'Show data'. 

Let's say that I think the extension ran into a problem with the max number of open sessions set for the DB schema owner.  Or some other theory.  Is there a log file, etc, I can check for details? - jdb

Best Answers

  • James Brockman
    James Brockman Member Posts: 7 Red Ribbon
    edited August 2019 Accepted Answer

    I generated another script file, this time with the extension *.plsql.  I've opened that file in a tab and hit F1.  Selected 'Change Language' and selected Oracle SQL and PL/SQL.  Ran the script, same error as before.

    All that said, the Micorosft SQL extension is installed.  Do we want to try uninstalling it and see what the differences are, or do you need some readings first? - jdb

  • James Brockman
    James Brockman Member Posts: 7 Red Ribbon
    Accepted Answer

    I am not able to reproduce the issue in version 19.3.3. Thanks for the follow-up. - jdb

Answers

  • Christian.Shay -Oracle
    Christian.Shay -Oracle Posts: 1,786 Employee
    edited August 2019

    After you press F1, is it prompting you to change the language and are you changing it to "Oracle SQL and PL/SQL"? Down on the very bottom of VS Code do you see "Oracle SQL and PL/SQL" when the .SQL file is selected?

    My concern is that the .SQL file is associated with some other extension like SQLTools or MSSQL.

    One way to avoid this headache is to rename the file to .PLSQL.

  • James Brockman
    James Brockman Member Posts: 7 Red Ribbon
    edited August 2019 Accepted Answer

    I generated another script file, this time with the extension *.plsql.  I've opened that file in a tab and hit F1.  Selected 'Change Language' and selected Oracle SQL and PL/SQL.  Ran the script, same error as before.

    All that said, the Micorosft SQL extension is installed.  Do we want to try uninstalling it and see what the differences are, or do you need some readings first? - jdb

  • Christian.Shay -Oracle
    Christian.Shay -Oracle Posts: 1,786 Employee

    Could you please try this out in the new 19.3.3 version and let me know if it is fixed for you?

  • James Brockman
    James Brockman Member Posts: 7 Red Ribbon
    Accepted Answer

    I am not able to reproduce the issue in version 19.3.3. Thanks for the follow-up. - jdb

Sign In or Register to comment.