CREATE FROM

From Recital Documentation Wiki
Revision as of 09:54, 28 April 2009 by Yvonnemilne (Talk | contribs)

Jump to: navigation, search

Class

Table basics


Purpose

Create a table from the contents of another table


Syntax

CREATE <filename1> | (<expC1>) FROM <filename2> | (<expC2>)


See Also

COPY, COPY STRUCTURE, COPY STRUCTURE EXTENDED, CREATE, SET CLIPPER


Description

The CREATE FROM command creates a new table, determined by the contents of a table created with the COPY STRUCTURE EXTENDED command. The filenames can be substituted with a <expC1>, enclosed in round brackets, which returns a valid filename. The FROM table consists of five fields, these are:


Field Type Width Description
FIELD_NAME Character 32 Field name
FIELD_TYPE Character 1 Data type of field
FIELD_LEN Numeric 3 Width of field
FIELD_DEC Numeric 3 Number of decimal places
FIELD_DES Character 25 Field Description


Each record of the FROM table defines a field. The structure of the new table, <filename1>, will be created from these field definitions.


Example

use patrons
copy structure extended to patstru
close patrons
create newpatron from patstru


Products

Recital Database Server, Recital Mirage Server, Recital Terminal Developer