Skip to content

This is my experiment to understand and learn Oracle SQL Developer Command Line (SQLcl).

License

Notifications You must be signed in to change notification settings

demasy/oracle-sqlcl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 

Repository files navigation

SQLcl (SQL Developer Command Line)

Oracle SQLcl (SQL Developer Command Line) is a modern, free command-line interface for Oracle Database, serving as a lightweight alternative to SQLPlus. It allows you to execute SQL and PL/SQL interactively or run scripts in batch. SQLcl enhances productivity with features from Oracle SQL Developer, including in-line editing, tab completion, command history, command recall for a feature-rich experience, and support for running existing SQLPlus scripts.

https://www.oracle.com/database/sqldeveloper/technologies/sqlcl/


Key Features

In-Line Editor

edit multi-line statements and scripts interactively at the SQLcl prompt

Change Management

native Liquibase integration, with automatic changelog generation for your Oracle Database objects

Command History

cycle through your 100 previous scripts/commands

Completion Insight

auto-complete object names or keywords using the tab key

New Commands

CTAS, DLL, Repeat, ALIAS, SCRIPT, FORMAT, and many more!

Client Side Scripting

execute javascript to manipulate query results, build dynamic commands, interact with the session, and much more

SQL*Plus Support

SQL*Plus environment settings, commands, and behaviors


Download


Install Oracle SQLcl & Connect on Database


sudo java --version
which java
cd /<$FILE_PATH>/sqlcl/bin
./sql <$USER_NAME>/<$PASSWORD>@<$HOST>:<$PORT>/<$SID>

Install Oracle SQLcl with Brew (Homebrew)

brew install --cask sqlcl

https://formulae.brew.sh/cask/sqlcl


Start SQLcl

./sql
./sql /nolog

Create a symbolic link (symlink)

Add to PATH

export PATH="$PATH:<Your Path>/sqlcl/bin"

Create symlink

sudo ln -s <Your Path>/sqlcl/bin /usr/local/bin/sql

Start SQLcl

sql ${username}/${password}@localhost:1521/FREE as sysdba

SQLcl Documentation