Products Downloads


French version


 


ADELIA

VADELIA

SADELIA

WADELIA

EADELIA

(I/B)

(I/B) (S)

(B) (S)

(I/B) (S)

(B) (S)


Section for use

All


Syntax

CREATE ViewName Parameter


Parameter

*NO_MR | *MR | None


Description

This instruction creates a record in the file which corresponds to the view ViewName.


The *MR parameter allows you to generate the creation implicit management rules that are linked to the entity corresponding to the view, even if the program is generated without the option to generate implicit management rules.


The *NO_MR parameter allows you not to generate the creation implicit management rules that are linked to the entity corresponding to the view, even if the program is generated with the option to generate implicit management rules.


Example

* Updates or creates a Customer

*

CHAIN CUSTOMER

IF   CUSTOMER EXISTS

UPDATE CUSTOMER

ELSE

CREATE CUSTOMER

END

*

* Manual loading for subfile

*

READ ORDER_LINES

DO_WHILE ORDER_LINES EXISTS

*

* Moves file fields into screen fields

*

ZORDER_LINE = ORDER_LINE

ZORDER_DATE = ORDER_DATE

ZORDER_QTY = ORDER_QTY

*

* Adds 1 in relative record number (WRAN01) of subfile

*

*DEL01 = *DEL01 + 1

WRAN01 = *DEL01

*

* Adds the record into the subfile

* Note: The SUBFILE_1 view is defined with *1 as the "File linked to the view"

*

CREATE SUBFILE_1

READ ORDER_LINES

REDO


↑ Top of page

  • Aucune étiquette