CLOSE TABLES

From Recital Documentation Wiki
Revision as of 14:34, 18 March 2009 by Yvonnemilne (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

CLOSE TABLES

Class

Databases


Purpose

Closes the currently open tables and their associated files in the active database


Syntax

CLOSE TABLES [ALL]


See Also

ADATABASES(), ALTER INDEX, ALTER TABLE, BACKUP DATABASE, CLOSE DATABASES, COMPILE DATABASE, CREATE DATABASE, DBUSED(),CREATE TABLE, CREATE INDEX, CREATE VIEW, DB_DATADIR, DISPLAY DATABASE, DISPLAY INDEXES, DISPLAY TABLES, DROP DATABASE, DROP INDEX, DROP TABLE, GETENV(), LIST DATABASE, LIST INDEXES, LIST TABLES, OPEN DATABASE, RESTORE DATABASE, USE, SET EXCLUSIVE


Description

The CLOSE TABLES command closes the currently open tables and their associated files in the active database. The database itself remains open. If no database is currently open, all tables and their associated files are closed.

If the ALL keyword is included, all tables and their associated files will be closed.

Databases in Recital are implemented as directories containing files that correspond to the tables and associated files in the database. Operating System file protection can be applied individually to the files for added security. The directories are sub-directories of the Recital data directory. The environment variable / symbol DB_DATADIR points to the current Recital data directory and can be queried using the GETENV() function. Files from other directories can be added to the database using the ADD TABLE command or via the database catalog and SET AUTOCATALOG functionality.


Example

Recital/SQL> set sql to vfp
VFP/SQL> OPEN DATABASE hr EXCLUSIVE
VFP/SQL> use staff
VFP/SQL> CLOSE TABLES


Products

Recital Database Server, Recital Mirage Server, Recital Terminal Developer