INSERT

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

Jump to: navigation, search

INSERT

Class

Screen Forms


Purpose

Insert a record into the active table at the current position


Syntax

INSERT

[BEFORE]

[BLANK]

[NOCLEAR]

[NOORGANIZE]


See Also

@...GET, APPEND, APPEND BLANK, APPEND FROM, CHANGE, CREATE, CREATE SCREEN, FMT(), SET CARRY


Description

The INSERT command is a full screen command used to insert records into the active table. A default form with blank fields will be activated on the screen. If the active table is indexed or if you are currently at the bottom of the table, then INSERT works just like APPEND.

You can design your own forms for inserting records with the Forms Designer (CREATE SCREEN). Once the form has been activated with SET FORMAT TO, it will be used instead of the default form when the INSERT command is issued.

Normally, all of the fields are initialized to blank. This behavior can be overridden with the SET CARRY ON command or the [CARRY MODE] key from within the append form. If SET CARRY is ON, data from the previous record will be carried over as the default for the next append operation. Default information may also be automatically inserted into the form via the Applications Data Dictionary.

Using INSERT on a non-indexed table is not recommended, since each time a record is inserted existing records have to be physically moved in the table. The APPEND command is the preferred solution.

BEFORE

The BEFORE keyword has been added solely for language compatibility with xBase products.

BLANK

If the BLANK option is specified, then a blank record is inserted after the current record and the INSERT form is not activated.

NOCLEAR

The NOCLEAR keyword disables the erasing of the screen on entry and exit from APPEND.

NOORGANIZE

The NOORGANIZE keyword has been added solely for language compatibility with Xbase products.

The following keys are active within an INSERT form.


Key Action
ABANDON Discard current record then exit from the form
CARRY MODE Toggle CARRY on and off
CURSOR DOWN Skip to next field
CURSOR LEFT Skip to previous field
CURSOR RIGHT Skip to next field
CURSOR UP Skip to previous field
DELETE FIELD Initialize field
EDIT FIELD Enter field edit mode
EXIT/SAVE Write current record then exit from the form
HELP Activate pop-up help
MENUBAR Activate the APPEND menu bar
NEXT RECORD Write current record then exit from the form
REFRESH Redraw the form
TAB Toggle function key menu on and off


If SET MOUSE is ON, cursor keys will move the cursor anywhere on the screen rather than just from field to field. If SET NAVIGATE is ON, the cursor moves to fields following the direction specified by the key being pressed, rather than following the order of the GETS on the form. When the RETURN key is pressed, the cursor moves to the nearest field when SET NAVIGATE is ON.

The following keys are active in field edit mode:


Key Action
BACKSPACE Delete character before cursor
CURSOR LEFT Skip to previous character
CURSOR RIGHT Skip to next character
DELETE CHAR Delete character under cursor
DELETE FIELD Delete from cursor to end of field
DELETE WORD Delete current word
INSERT MODE Toggle insert / overwrite mode
WORD LEFT Skip left a word
WORD RIGHT Skip right a word


The following menu options are available from the INSERT menu bar in the default form:


Menu Item Action
Descriptions Toggle the field descriptions on and off
Help Activate on-line help system


Example

use patrons index names
insert


Products

Recital Mirage Server, Recital Terminal Developer