Products Downloads


French version


 


      

VADELIA

      

WADELIA



(I/B) (C/S)


(I/B) (C/S)



Section for use

All


Syntax

PRESENT ViewOrEntityOrAccess WindowOrPage Option


WindowOrPage

WindowOrPageName | None




Option

*FORCE | None


Description

This instruction loads fields from the file or SQL table into the corresponding layout fields. This instruction is the opposite of the BRING_BACK instruction.


Where a view has the same name as an entity, the view name will take priority.


The layout fields concerned are those in the current window (Visual Adelia context), or page (Adelia Web context), unless the window or page name WindowOrPageName is specified, in which case the fields concerned will be those in the specified window or page (Visual context).


With "PRESENT View" instructions, if *FORCE option is not mentioned and the previous reading of the view was not completed successfully, the layout fields are cleared or set to zero.


With "PRESENT Entity" instructions, the layout fields are cleared or set to zero if *FORCE option is not mentioned and the previous SQL reading of the entity was not completed successfully (*SQLCODE <> 0).


"PRESENT Access" applies when the access is used to load a graphic list.


With interactive programs, only active objects in the data flow are concerned.

With batch programs, all fields with a logical origin are concerned.


Note: As this instruction does not make any database accesses, it can be included in either the client or the server part of a program.


Example

CHAIN INVOICE_VIEW

PRESENT INVOICE_VIEW UPDATE_WINDOW


CHAIN_SQL ORDER_LINE *COND(OORDER_NUM = :ZORDER_NUM AND OORDER_LINE = 1)

PRESENT ORDER_LINE


Other example


* Read loop on a list to collect all the selected lines to be modified

READ_LST EMPLOYEES_LST:LIST *SELECT

*

E_ACTION_COD = 'MO'

E_IDNBR_COD = *BLANK   

E_IDNBR_COD = ZZ_IDNBR_COD

*

CALL UPD_EMPLOYEES E_IDNBR_COD E_ACTION_COD

IF E_ACTION_COD = 'OK'

CHAIN_SQL EMPLOYEES *COND(EM_IDNBR_COD = :E_IDNBR_COD)

PRESENT EMPLOYEES

CHANGE_ELT EMPLOYEES_LST:LIST *DESELECT

END

*

END_READ_LST


↑ Top of page

  • Aucune étiquette