OracleSQL icon indicating copy to clipboard operation
OracleSQL copied to clipboard

Fails to run on UNIX/Mac systems

Open davidhooey opened this issue 12 years ago • 4 comments

It would be awesome if it would work on UNIX systems. I hacked it to work on my Mac with the Oracle Instant Client (11.2.0.3).

Check out the hack here.

https://github.com/davidhooey/OracleSQL/commit/f483d71de35be267c30cac2a4fb7eaafb98656de

Basically four things that needed to be done.

  1. Set the DYLD_LIBRARY_PATH environment variable to be system wide.
$ launchctl setenv DYLD_LIBRARY_PATH $DYLD_LIBRARY_PATH 
  1. Add the Instant Client to the PATH variable so Sublime can see it.
  2. Change sqlplus.exe to sqlplus.
  3. For some reason the USER_ERRORS query was failing. I should investigate this further but for now I removed this one query.

Also, Easy Connect needs to be used or Sublime will need to know how to get to the tnsnames.ora file. My build command file looks as follows.

{
    "target": "oracle_exec",
    "selector": "source.plsql.oracle",
    "variants":
    [
        {
            "name": "hooey-davidh",
            "dsn": "davidh/oracle@//hooey.mydomain.net/orcl"
        }
    ]
}

Thanks!

davidhooey avatar Sep 06 '13 18:09 davidhooey

Sorry for the late answer.

I only use Oracle on a Windows box, so I've no idea what to do on other OS to make it works. But doesn't the point 1 and 2 be addressed from outside ST ? Or don't you have to do this for every application that use Oracle client ?

bizoo avatar Oct 07 '13 06:10 bizoo

Yes, that is correct! Points 1 and 2 are configuration steps for the Oracle Instant Client.

davidhooey avatar Oct 07 '13 12:10 davidhooey

Thanks for your quick reply. So basically the only thing to change is the sqlplus binary name ? And add the configuration steps to the readme.

bizoo avatar Oct 07 '13 14:10 bizoo

Yes, however there is still the issue with the USER_ERRORS which I have not figured out yet. I can test some more and see if I can figure it out.

davidhooey avatar Oct 07 '13 14:10 davidhooey