Skip to content

TAB completion for SQL*Plus filenames and commands using rlwrap

License

Notifications You must be signed in to change notification settings

bsjerps/sqlwrap

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

sqlwrap

SQLWrap provides TAB completion for SQL*Plus filenames and commands using rlwrap.

Description

sqlwrap executes rlwrap sqlplus with parameters to enable command history and command completion for .sql scripts and sql commands. sqlwrap uses an rlwrap filter ’sqlplus_filter’ which reads all sql scripts in the current working directory and $SQLPATH (and subdirs), prepends them with ’@’ and adds them as possible completions when using sqlplus. It also loads all readable wordlists matching:

/usr/share/rlwrap/completions/sqlplus.*

Download

It is recommended to install via YUM (See [Installation](# Installation)).

Features

  • Autocompletes SQL scripts starting with '@' on the SQL*Plus command line for all .sql scripts in $SQLPATH, its subdirectories and the current working directory.
  • Autocompletes all words from $RLWAP_HOME/completions/sqlplus.* after typing the first 2 characters
  • Blacklists words in the wordlists if they start with '-'

Requirements

  • Oracle SQL*PLus (sqlplus executable) in $ORACLE_HOME/bin
  • rlwrap installed

Installation

from YUM repository (recommended)

yum install https://yum.dirty-cache.com/dcrepo-release.rpm
yum install sqlwrap

From source

Download or clone from GIT, cd to the src directory. Then

make install

Or, if you don't have root access:

make user

(this will install sqlwrap in $HOME/bin and $HOME/sqlwrap)

Manual

See MAN PAGE

Example

See below for an example of sqlwrap in action.

example1

Blogpost

SQLWrap to the rescue

Future

  • Better wordlists?

Licensing

sqlwrap is licensed under GPLv3. See "COPYING" for more info.

Support

Please file bugs and issues at the Github issues page.

About

TAB completion for SQL*Plus filenames and commands using rlwrap

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published