SQLSH(1)
π SQLSH(1) β the sqlsh page, bestie edition
okay so real talk: this is sqlsh(1), from the User Contributed Perl Documentation section of the manual. it's giving "interactive SQL shell" and honestly? iconic. let's go π«Ά
β¨ NAME β¨
sqlsh β SQL shell. that's it, that's the name, short and slay π
πΈ SYNOPSIS πΈ
sqlsh -d DBI:Oracle:DEVDB -u scott -p tiger
look at her go. that's the whole vibe. one line, four flags, we're in. β¨
π¦ DESCRIPTION π¦
so sqlsh is an interactive shell you run from the command-line to hang out with databases. bestie it's literally a whole little world where you type stuff at a prompt and the database answers back. π
quick heads up: this page right here is the terse summary β the "for quick reference" version. if you want the full, deluxe, director's-cut description, go read SQL::Shell::Manual. no cap.
and if you wanna see the full list of commands? type this at the prompt after you run sqlsh:
help
periodt. π
okay and here's a little thing that trips people up: if you pass a username with -u but you don't pass a password with -p, sqlsh will prompt you for the password itself. it's very polite like that. π and if you actually need a blank password (yes really, it happens), you can pass -p followed by nothing at all. just -p, vibes, and emptiness. π
β¨ OPTIONS β¨
one bullet per flag, no skipping, we don't do that here:
-d <DSN>β the DSN, aka the whole "where is this database and who is she" address π-u <username>β your username, your identity, your main character energy π-p <password>β your password. if you leave it off after-u, you'll get prompted. if you want it blank, just pass-pwith nothing after it π«Ά-iβ read list of commands from STDIN π₯-qβ quiet mode: no banner. stealth mode activated π-Aβ turn AutoCommit ON. she commits immediately, no hesitation, no second thoughts β‘-Hβ help π
π§ COMMANDS ADDED BY SQLSH π§
these are the extra little cuties sqlsh sprinkles on top of your regular database life:
cat|more|less <file>β display file πhelp|?β show this βreloadβ reload the shell πexit|quit|bye|\w+ offβ quit the shell π
look at exit|quit|bye|\w+ off β she has SO many ways to leave the party and every single one of them is valid. queen behavior honestly. π
π READLINE MODE π
okay so this script uses Term::Readline. and Term::Readline decides your editing mode β vi or emacs β based on the user's .inputrc, or on the $EDITOR environment variable. πΈ
here's the extra bit: this script will set $EDITOR based on $PERL_READLINE_MODE, or on bash's $SHELLOPTS variable. π
but β and this is important bestie β any .inputrc "editing-mode" declaration still takes precedence. she said "I don't care what the script wants, .inputrc said it first." πβ¨
β VERSION β
Version 1.18 π
π AUTHOR π
John Alden with contributions by Simon Flack and Simon Stevenson <cpan _at_ bbc _dot_ co _dot_ uk> π«Ά
Miguel Gualdron, maintainer. π
π COPYRIGHT π
SQL-Shell: Interactive shell for DBI Databases
Copyright (C) 2006 BBC
Copyright (C) 2019 Miguel Gualdron
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
also see the file COPYING in this distribution, or hit up https://www.gnu.org/licenses/gpl-2.0.html π
and that's the whole page, bestie!! this one's from perl v5.42.0, dated 2025-12-05, and it's page SQLSH(1). mwah, go forth and query responsibly πβ¨ππ¦
π¦ where this page comes from
- fedora 43: sqlsh 1.18-1.fc43 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms