Sqlplus Download Mac

Posted on  by 

Download Sql Plus 64 Mac Emulator Version 10.2.0.4 (32-bit) Plus Sql Download For Pc. Name Download Description; Instant Client Package - Basic: All files required to. If you set up NFS, then you can download and unzip Oracle on the Mac, into a directory you share using NFS (www.oracle.com, Downloads, look for Database 10g for Linux, 32 bit).3 While it's downloading, it might be a good time to install your favourite Firefox bookmark synchronisation service - I use Foxmarks. SQL.Plus Commander is Text-based user interface (TUI) / framework to query data on Oracle DB in a smart way. It consists in a fully customizable script shell for bash and ksh. It executes custom queries or procedures on DB with SQLPlus for Oracle. The results of queries can be browsed in a colorful text interface resulting data from a query can. How do I download SQL Plus for Mac? Install SQL.Plus 12.2 on a Mac. Navigate to Oracle downloads, accept the license agreement, and login. Download these zip files: Make dir for instant client then unzip zips mkdir -p /bin/oracle unzip -d /bin/oracle instantclient-basic-macos.x64-12.2.0.1.0-2.zip unzip -d /bin/oracle instantclient-sqlplus. Instant Client 19.8 supports macOS High Sierra, Mojave, Catalina, and Big Sur. In Finder, double click on all desired Instant Client.dmg packages to mount them. All installations require the Basic or Basic Light package. Open a terminal window and change directory to one of the packages, for example.

SQL*Plus Instant Client is a standalone product with all the functionality of SQL*Plus command-line. It connects to existing remote Oracle databases, but does not include its own database. It is easy to install and uses significantly less disk space than the full Oracle Database Client installation required to use SQL*Plus command-line.

SQL*Plus Instant Client is available on platforms that support the OCI Instant Client. See the Oracle Call Interface Programmer's Guide for more information on the OCI Instant Client.

To install SQL*Plus Instant Client, you need two packages:

  • SQL*Plus Instant Client package.

  • Either the Basic OCI Instant Client package, or the lightweight OCI Instant Client package.

Choosing the SQL*Plus Instant Client to Install

SQL*Plus Instant Client can be installed in two ways:

  • Download the packages from the Oracle Technology Network (OTN).

  • Copy the same files that are in the packages from an Oracle Database 10g Client Administrator installation.

Both the SQL*Plus and OCI packages must be from the same Oracle Database version, for example, 10.2.0.1.

Basic Instant Client

SQL*Plus Instant Client using the Basic OCI package works with any NLS_LANG setting supported by the Oracle Database. It supports all character sets and language settings available in the Oracle Database.

Lightweight Instant Client

SQL*Plus Instant Client using the lightweight OCI package displays error messages in English only and supports only specific character sets. It is significantly smaller than SQL*Plus Instant Client using the Basic OCI package.

Valid values for NLS_LANG parameters with the lightweight Instant Client are:

  • language must always be American.

  • territory can be any valid territory supported by the Oracle Database.

  • charset is one of the following character sets:

    • US7ASCII

    • WE8DEC

    • UTF8

    • AL16UTF16

    • AL32UTF8

For example:

See the Oracle Database Globalization Support Guide, and NLS_LANG Environment Variable for more information about NLS settings.

Lightweight SQL*Plus Instant Client Error with Unsupported Character Set

Attempting to start SQL*Plus Instant Client with an unsupported character set will fail with the following error:

Installing SQL*Plus Instant Client by Downloading from OTN

The OTN downloads for Linux are RPM packages. The OTN downloads for UNIX and Windows are zip files.

The SQL*Plus Instant Client package should never be installed on an ORACLE_HOME.

Installing SQL*Plus Instant Client from Linux RPM Packages

  1. Download the RPM packages containing the SQL*Plus Instant Client package, and the OCI package from the OTN Instant Client page at http://www.oracle.com/technology/tech/oci/instantclient/instantclient.html. Both packages must be from the same version such as 10.2.0.1.

  2. Use rpm -i for the initial install of the RPM packages, or rpm -u to upgrade to a newer version of the packages.

  3. Configure SQL*Plus Instant Client. See Configuring SQL*Plus Instant Client.

Installing SQL*Plus Instant Client from the UNIX or Windows Zip Files

  1. Download the zip files containing the SQL*Plus Instant Client package, and the OCI package from the OTN Instant Client page at http://www.oracle.com/technology/tech/oci/instantclient/instantclient.html. Both packages must be from the same version such as 10.2.0.1.

  2. Create a new directory, for example, /home/instantclient10_2 on UNIX or c:instantclient10_2 on Windows.

  3. Unzip the two packages into the new directory.

  4. Configure SQL*Plus Instant Client. See Configuring SQL*Plus Instant Client.

List of Files Required for SQL*Plus Instant Client

Tables E-1, E-2 and E-3 list the required files from each of the SQL*Plus and OCI packages. The files from only one of the OCI packages are required. Other files installed that are not listed here can be ignored, or can be removed to save disk space.

Table E-1 Instant Client Files in the SQL*Plus Package

Linux and UNIXWindowsDescription

sqlplus

sqlplus.exe

SQL*Plus executable

libsqlplus.so

not applicable

SQL*Plus library

libsqlplusic.so

orasqlplusic10.dll

SQL*Plus data shared library

glogin.sql

glogin.sql

SQL*Plus site profile


Table E-2 Instant Client Files in the Basic OCI Package

Linux and UNIXWindowsDescription

libclntsh.so.10.1

oci.dll

Client code library

libociei.so

oraociei10.dll

OCI Instant Client data shared library

libnnz10.so

orannzsbb10.dll

Security library


Table E-3 Instant Client Files in the Lightweight OCI Package

Linux and UNIXWindowsDescription

libclntsh.so.10.1

oci.dll

Client code library

libociicus.so

oraociicus10.dll

OCI Instant Client data shared library (English only)

libnnz10.so

orannzsbb10.dll

Security library


Installing SQL*Plus Instant Client from the 10g Client Release Media

  1. Run the installer on the Oracle Database 10g Client Release media and choose the Administrator option.

  2. Create a new directory, for example, /home/instantclient10_2 on UNIX and Linux, or c:instantclient10_2 on Windows.

  3. Copy the SQL*Plus Instant Client and the OCI Instant Client files to the new directory. All files must be copied from the same ORACLE_HOME.

    See Installing SQL*Plus Instant Client on UNIX or Linux or Installing SQL*Plus Instant Client on Windows for a list of the files to copy.

  4. Configure SQL*Plus Instant Client. See Configuring SQL*Plus Instant Client.

Installing SQL*Plus Instant Client on UNIX or Linux

To install SQL*Plus Instant Client using the Basic OCI package on UNIX and Linux, copy the following files:

To install SQL*Plus Instant Client using the lightweight OCI package on UNIX and Linux, copy the following files:

Installing SQL*Plus Instant Client on Windows

To install SQL*Plus Instant Client using the Basic OCI package on Windows, copy the following files:

To install SQL*Plus Instant Client using the lightweight OCI package on Windows, copy the following files:

Configuring SQL*Plus Instant Client

The SQL*Plus Instant Client executable should only be used with the matching version of the OCI Instant Client.

Note that no ORACLE_HOME or ORACLE_SID environment variables need to be set.

Configuring SQL*Plus Instant Client on Linux (from RPMs)

The RPMs downloaded from OTN install into Oracle specific sub-directories in the /usr file system. The sub-directory structure enables multiple versions of Instant Client to be available.

  1. Add the name of the directory containing the Instant Client libraries to LD_LIBRARY_PATH. Remove any other Oracle directories.

    For example, to set LD_LIBRARY_PATH on Solaris in the Bourne or Korn shells:

  2. Make sure the sqlplus executable installed from the RPM is the first found in your PATH. To test, enter which sqlplus which should return /usr/bin/sqlplus. If not, remove any other Oracle directories from PATH, or put /usr/bin before other SQL*Plus executables in PATH, or use an absolute or relative path to start SQL*Plus.

    For example, to set PATH in the bash shell:

    If you install multiple versions of SQL*Plus, you may need to change the symbolic link /usr/bin/sqlplus to the version of SQL*Plus matching the libraries in LD_LIBRARY_PATH. For 10.2.0.1, /usr/bin/sqlplus is a symbolic link to the SQL*Plus binary at /usr/lib/oracle/10.2.0.1/client/bin/sqlplus.

  3. Set SQLPATH to the directory containing glogin.sql. For example:

  4. Set Oracle globalization variables required for your locale. A default locale will be assumed if no variables are set. See the Oracle Database Globalization Support Guide for more information.

    For example:

Configuring SQL*Plus Instant Client on Linux (from Client Media or Zip File) and UNIX

  1. Add the name of the directory containing the Instant Client files to the appropriate shared library path LD_LIBRARY_PATH, LIBPATH or SHLIB_PATH. Remove any other Oracle directories.

    For example on Solaris in the Bourne or Korn shells:

  2. Add the directory containing the Instant Client files to the PATH environment variable. If it is not set, then an absolute or relative path must be used to start SQL*Plus. Remove any other Oracle directories from PATH. For example:

  3. Set SQLPATH to the directory containing the Instant Client files so glogin.sql can be found. For example:

  4. Set Oracle globalization variables required for your locale. A default locale will be assumed if no variables are set. See the Oracle Database Globalization Support Guide for more information.

    For example:

Configuring SQL*Plus Instant Client on Windows

Sqlplus Download Mac

The environment may be configured using SET commands in a Windows command prompt or made permanent by setting Environment Variables in System Properties.

For example, to set environment variables in Windows 2000 using System Properties, open System from the Control Panel, click the Advanced tab and then click Environment Variables.

  1. Add the directory containing the Instant Client files to the PATH system environment variable. Remove any other Oracle directories from PATH.

    For example, add c:instantclient10_2 to the beginning of PATH.

  2. Set the user environment variable SQLPATH to the directory containing the Instant Client files so glogin.sql is found.

    For example, create a user variable SQLPATH set to c:instantclient.

  3. Set Oracle globalization variables required for your locale. A default locale will be assumed if no variables are set. See the Oracle Database Globalization Support Guide for more information. For example, to set NLS_LANG for a Japanese environment, create a user environment variable NLS_LANG set to JAPANESE_JAPAN.JA16EUC.

    If you have installed the lightweight Instant Client, see Lightweight Instant Client for information about supported NLS_LANG settings.

Connecting to a Database with SQL*Plus Instant Client

SQL*Plus Instant Client is always 'remote' from any database server. To connect to a database you must specify the database using an Oracle Net connection identifier.

An example using an Easy Connection identifier to connect to the HR schema in the MYDB database running on mymachine is:

Alternatively you can use a Net Service Name:

Net Service Names can be stored in a number of places, including LDAP. The use of LDAP is recommended to take advantage of the new features of Oracle Database 10g. See the Oracle Database Net Services Reference for more information.

If you want to use Net Service Names configured in a local Oracle Net tnsnames.ora file, then set the environment variable TNS_ADMIN to the directory containing the tnsnames.ora file. For example, on UNIX, if your tnsnames.ora file is in /home/user1 and it defines the Net Service Name MYDB2:

If TNS_ADMIN is not set, then an operating system dependent set of directories is examined to find tnsnames.ora. This search path includes looking in the directory specified by the ORACLE_HOME environment variable for network/admin/tnsnames.ora. This is the only reason to set the ORACLE_HOME environment variable for SQL*Plus Instant Client. If ORACLE_HOME is set when running Instant Client applications, it must be set to a directory that exists.

This example assumes the ORACLE_HOME environment variable is set, and the $ORACLE_HOME/network/admin/tnsnames.ora or %ORACLE_HOME%networkadmintnsnames.ora file defines the Net Service Name MYDB3:

The TWO_TASK (on UNIX) or LOCAL (on Windows) environment variable can be set to a connection identifier. This removes the need to explicitly enter the connection identifier whenever a connection is made in SQL*Plus or SQL*Plus Instant Client. This UNIX example connects to the database known as MYDB4:

Download

On Windows, TNS_ADMIN and LOCAL may be set in the System Properties. See Configuring SQL*Plus Instant Client on Windows.

AS SYSDBA or AS SYSOPER Connections with SQL*Plus Instant Client

To connect AS SYSDBA or AS SYSOPER to perform DBA tasks, you need to set up an Oracle password file on the database server using the database's orapwd utility. Once this is configured, your SQL*Plus Instant Client connection string might look something like:

See the Oracle Database Administrator's Guide for information on Oracle password files.

Uninstalling Instant Client

The SQL*Plus Instant Client package can be removed separately from the OCI Instant Client. After uninstalling the SQL*Plus Instant Client package, the remaining OCI Instant Client libraries enable custom written OCI programs or third party database utilities to connect to a database.

Uninstalling SQL*Plus Instant Client

  1. For installations on Linux from RPM packages, use rpm -e only on the SQL*Plus Instant Client package

    or

    For installations on UNIX and Windows, and installations on Linux from the Client Release media, manually remove the following SQL*Plus specific files:

    Table E-4 Instant Client Files in the SQL*Plus Package

    UNIXWindowsDescription

    sqlplus

    sqlplus.exe

    SQL*Plus executable

    glogin.sql

    glogin.sql

    SQL*Plus site profile

    libsqlplus.so

    not applicable

    SQL*Plus library

    libsqlplusic.so

    orasqlplusic10.dll

    SQL*Plus data shared library


  2. Reset environment variables and remove tnsnames.ora if necessary.

Uninstalling the Complete Instant Client

Sql Plus Download Oracle

  1. For installations on Linux from RPM packages, use rpm -qa to find the SQL*Plus Instant Client and Basic OCI package names and run rpm -e to remove them

    or

    For installations on UNIX and Windows, and installations on Linux from the Client Release media, manually delete the directory containing the SQL*Plus executable, Oracle libraries and glogin.sql.

    See Installing SQL*Plus Instant Client from the 10g Client Release Media for a list of the files you copied to the directory.

  2. Reset environment variables such as PATH, SQLPATH, LD_LIBRARY_PATH and TNS_ADMIN.

  3. Remove tnsnames.ora if necessary.

Have you ever tried to spool/download BLOBS with SQL*Plus? Some months ago I tried to find a way to download a collection of CLOBs or even better a zipped version of the collection as BLOB. I learned that BLOBs are not a valid datatype in SQL*Plus when it comes to the spool command. I found a way by putting the CLOBs into a global temporary table, creating an intermediate SQL script with tons of select and spool commands, and finally spooling the CLOBs one by one by calling the intermediate SQL script. It was working, but far from elegant. Also, when I was in the home office with a less powerful connection, it was slowing down the whole export process significantly.

If you are using PLEX (PL/SQL Export Utilities) and this sounds familiar to you - the described method was the default for exporting an APEX app or your schema DDL with the delivered export script templates.

If you have no idea what I am talking about: PLEX is a PL/SQL package that is able to export an Oracle APEX app, ORDS modules, all schema objects and table data into a nice directory structure in one go ready to use for version control. Check out the project on GitHub and this blog post on how to get started.

But there is a better way: Simply convert the BLOB into a base64 encoded CLOB. I have no idea why this was not my first solution for the PLEX export templates. In the new version 2.1.0 of PLEX the templates are using this approach. Here is a simplified example.

File export.sql:

Congratulations - You are the owner of a base64 encoded CLOB on your client disk. And now? Before you can unzip the file you need to decode it - depending on your operating system you can do this with your OS tools:

  • Windows: certutil -decode app_100.zip.base64 app_100.zip
  • Mac: base64 -D -i app_100.zip.base64 -o app_100.zip
  • Linux: base64 -d app_100.zip.base64 > app_100.zip

Free Oracle Sql Plus Download

Here a simple Windows batch file, which calls the SQL script above, decodes the file and deletes the base64 version.

File export.bat

The described method to download a BLOB is independent of the package PLEX - you only need a small helper function to encode the BLOB. I found an example provided by Tim Hall on his Oracle Base site. Thanks for sharing Tim!

This function is included in the newest version of PLEX (named to_base64) - you can download PLEX here.

Happy scripting, exporting and version controlling :-)

Sql Plus Download Mac Os

Ottmar

Coments are closed