1
2isql(1)                      UnixODBC manual pages                     isql(1)
3
4
5

NAME

7       isql, iusql - unixODBC command-line interactive SQL tool
8
9

SYNOPSIS

11       isql DSN [USER [PASSWORD]] [options]
12
13

DESCRIPTION

15       isql  is  a  command  line tool which allows the user to execute SQL in
16       batch or interactively. It has some  interesting  options  such  as  an
17       option to generate output wrapped in an HTML table.
18
19       iusql is the same tool with built-in Unicode support.
20
21

ARGUMENTS

23       DSN    The Data Source Name, which should be used to make connection to
24              the  database.   The  data  source  is   looked   for   in   the
25              /etc/odbc.ini  and $HOME/.odbc.ini files in that order, with the
26              latter overwriting the former.
27
28
29       USER   Specifies the database  user/role  under  which  the  connection
30              should be made.
31
32
33       PASSWORD
34              Password for the specified USER.
35
36

OPTIONS

38       -b     Run  isql  in non-interactive batch mode. In this mode, the isql
39              processes its standard input,  expecting  one  SQL  command  per
40              line.
41
42
43       -dDELIMITER
44              Delimits columns with delimiter.
45
46
47       -xHEX  Delimits  columns  with  HEX, which is a hexadecimal code of the
48              delimiting character in the format 0xNN - i.e. 0x09 for the  TAB
49              character.
50
51
52       -w     Format the result as HTML table.
53
54
55       -c     Output the names of the columns on the first row. Has any effect
56              only with the -d or -x options.
57
58
59       -mNUM  Limit the column display width to NUM characters.
60
61
62       -lLOCALE
63              Sets locale to LOCALE.
64
65
66       -q     Wrap the character fields in double quotes.
67
68
69       -3     Use the ODBC 3 calls.
70
71
72       -n     Use the new line processing. (multiple lines of SQL,  terminated
73              with command GO).
74
75
76       -e     Use the SQLExecDirect instead of Prepare.
77
78
79       -k     Use SQLDriverConnect.
80
81
82       -v     Turn  on the verbose mode, where the errors are fully described.
83              Useful for debugging.
84
85
86       --version
87              Prints the program version and exits.
88
89
90       -LNUM  Alter the maximum number of characters displayed from a  charac‐
91              ter field to NUM characters. Default is 300.
92
93

COMMANDS

95       This section briefly describes some isql runtime commands.
96
97       help
98              List all tables in the database.
99
100       help table
101              List all columns in the table.
102
103       help help
104              List all help options.
105
106

EXAMPLES

108       $ isql WebDB MyID MyPWD -w -b < My.sql
109
110       Connects  to  the  WebDB as user MyID with password MyPWD, then execute
111       the commands in the My.sql file and returns the results wrapped in HTML
112       table.   Each line in My.sql must contain exactly 1 SQL command, except
113       for the last line, which must be blank (unless the -n option is  speci‐
114       fied).
115
116

FILES

118       /etc/odbc.ini
119              System-wide DSN definitions. See odbc.ini(5) for details.
120
121       $HOME/.odbc.ini
122              User-specific DSN definitions. See odbc.ini(5) for details.
123
124

SEE ALSO

126       odbcinst(1), odbc.ini(5)
127
128

AUTHORS

130       The authors of unixODBC are Peter Harvey <pharvey@codebydesign.com> and
131       Nick Gorham <nick@lurcher.org>. For the full list of  contributors  see
132       the AUTHORS file.
133
134
136       unixODBC  is  licensed under the GNU Lesser General Public License. For
137       details about the license, see the COPYING file.
138
139
140
141version 2.3.6                   Tue 25 Jun 2013                        isql(1)
Impressum