ISQL and Tools

The file name must be enclosed in doubles quotes, such as: isql -s "test script.sql" testdb

-u user_name

The user name c-treeSQL uses to connect to the database specified in the connect_string. c- treeSQL verifies the user name against a corresponding password before it connects to the database. If omitted, the default value depends on the environment. (On UNIX, the value of the DH_USER environment variable specifies the default user name. If DH_USER is not set, the value of the USER environment variable specifies the default user name.)

-a password

The password c-treeSQL uses to connect to the database specified in the connect_string. c- treeSQL verifies the password against a corresponding user name before it connects to the database. If omitted, the default value depends on the environment. (On UNIX, the value of the DH_PASSWD environment variable specifies the default password.)

connect_string

A string that specifies which database to connect to. The connect_string can be a simple data- base name or a complete connect string. For example, to connect to a local database named myDatabase, you would use the following syntax:

isql -u ADMIN -a ADMIN myDatabase

To connect to a remote database named c-treeSQL, you would use the 6597@remotehost:data- base syntax as follows:

isql -u ADMIN -a ADMIN 6597@hotdog.faircom.com:ctreeSQL

See the CONNECT statement in the c-treeSQL Reference Manual for details on how to spec- ify a complete connect string. If omitted, the default value depends on the environment. (On UNIX, the value of the DB_NAME environment variable specifies the default connect string.)

3.3STATEMENT HISTORY SUPPORT

ISQL provides statements to simplify the process of executing statements you already typed. ISQL implements a history mechanism similar to the one found in the csh (C-shell) supported by UNIX.

The following table summarizes the ISQL statements that support retrieving, modifying, and rerunning previously entered statements.

Table 3-1: ISQL Statements for Statement History Support

Statement

Summary

 

 

HISTORY

Displays a fixed number of statements (specified by the SET HIS-

 

TORY statement) which have been entered before this state-

 

ment, along with a statement number for each statement. Other

 

statements take the statement number as an argument. See Sec-

 

tion 3.7.12 "HISTORY" on page 3-29 for details.

 

 

3-2

FairCom Corporation

Page 28
Image 28
HP c-tree-SQL ISQL and Tools manual Statement History Support, Username, Password, Connectstring