Product Documentation

FairCom ISQL

Previous Topic

Next Topic

SAVE

Syntax

S[AVE] filename;

Description

The SAVE statement saves the last statement in the history buffer in filename. The GET and START statements can then be used to read and execute the statement from a file.

If filename does not exist, ISQL creates it. If filename does exist, ISQL overwrites it with the contents of the last statement in the history buffer.

Example


ISQL> ! more test.SQL

test.sql: No such file or directory

ISQL> select customer_name, customer_city from customers;

CUSTOMER_NAME CUSTOMER_CITY

------------- -------------


Sports Cars Inc. Sewickley

Mighty Bulldozer Inc. Baldwin Park

Ship Shapers Inc. South Miami

Tower Construction Inc. Munising

Chemical Construction Inc. Joplin

Aerospace Enterprises Inc. Scottsdale

Medical Enterprises Inc. Denver

Rail Builders Inc. Claymont

.

.

.

ISQL> save test.sql

ISQL> ! ls -al test.sql

-rw-r--r-- 1 ADMIN 51 May 1 18:21 test.sql

ISQL> ! more test.sql

select customer_name, customer_city from customers

ISQL>


TOCIndex