=head1 NAME

isql -- Firebird Interactive SQL shell

=head1 SYNOPSIS

B<isql> [-a] [-cache I<number>] [-database I<path>] [-echo] [-input I<file>]
[-merge_stderr] [-noautocommit] [-nowarnings] [-output I<file>] [-password
I<string>] [-page I<number>] [-role I<string>] [-s I<number>] [-terminator
I<string>] [-user I<name>] [-x] [-z]

=head1 DESCRIPTION

B<isql> is a program that allows the user to issue arbitrary SQL commands
as well as exctacting the metadata.

B<isql> in B<Debian> is available under the B<isql-fb> name due to filename
conflict with an executable from another package.

=head1 OPTIONS

B<isql> can handle various command line options. Most options can be
abbreviated. Below are given the shortest abbreviations as well as the full
versions.

=over

=item B<-a>

Extract DDL (Data definition language) statements necessary to re-create
database's structure, triggers and other metadata. The C<CREATE DATABASE>
statement is in a comment. Statements are printed to standard
output unless L<-output> is used. See also L<-extract>.

=item B<-c> I<buffers>

=item B<-cache> I<number>

Specify default size of the buffers to be used in database pages.

=item B<-d> I<path>

=item B<-database> I<path>

Specifies target database name when extracting the metadata with the
L<-extract> option.

=item B<-e>

=item B<-echo>

Prints each statement before executing it.

=item B<-x>

=item B<-ex>

=item B<-extract>

Extracts DDL statements to recreate database metadata.

If no L<-database> option is given, B<-extract> behaves exactly as L<-a>. If
L<-database> is given, the C<CREATE DATABASE> statement is not commented and
the database name is replaced with I<path>.

=item B<-i> I<file>

=item B<-input> I<file>

Reads commands from I<file> instead of standard input. Exits with commit after
the last command.

=item B<-m>

=item B<-merge_stderr>

Merges standard error to standard output. Useful for redirecting both streams.

=item B<-n>

=item B<-noautocommit>

Normally, all DDL statements like C<CREATE TABLE> are automatically committed
in a separate transaction. This option disables the automatic commit of DDL
statements.

=item B<-nowarnings>

Disables displaying of SQL warnings.

=item B<-o> I<file>

=item B<-output> I<file>

All output is redirected to the given I<file>.

=item B<-page> I<number>

=item B<-pagelength> I<number>

Prints column headers every I<number> output lines. Default is C<20>.

=item B<-pas> I<string>

=item B<-password> I<string>

Uses given password as a default when connecting to databases.

=item B<-r> I<string>

=item B<-role> I<string>

Uses given SQL role as a default when connecting to databases.

=item B<-s> I<number>

=item B<-sqldialect> I<number>

Uses given SQL dialect as a default when connecting to databases. The default
is C<1>.

=item B<-t> I<string>

=item B<-terminator> I<string>

Set command line terminator. Default is semicolon C<;>.

=item B<-u> I<string>

=item B<-user> I<string>

Uses given user name as a default when connecting to databases.

=item B<-z>

Prints program version string before doing anything else. Prints server version
after connecting to a database.

=back

=head1 ENVIRONMENT

=over

=item B<ISC_USER>

Default value for the L<-user> option.

=item B<ISC_ROLE>

Default value for the L<-role> option.

=item B<ISC_PASSWORD>

Default value for the L<-password> option.

=back

=head1 SEE ALSO

L<gbak(1)>, L<gfix(1)>, L<fbstat(1)>.

Additional documentation about Firebird can be found on the Firebird Project
website, L<http://www.firebirdsql.org>.

=head1 AUTHOR

This manual page was written by Damyan Ivanov L<dmn@debian.org> for the Debian
project. Permission is granted to use this document, with or without
modifications, provided that this notice is retained. If we meet some day, and
you think this stuff is worth it, you can buy me a beer in return.
