9 112 GET_ILENTRY_LIST

LANSA Technical

9.112 GET_ILENTRY_LIST

Þ Note: Built-In Function Rules.

Retrieves a list of Impact List entries and their descriptions from the data dictionary and returns them to calling RDML function in a variable length working list. The Impact List must have been previously created and entries added using the LANSA development menu.

Þ This is a Specialized Built-In Function for use in a Development Environment only.

For use with

LANSA for i

YES

Not available for RDMLX.

Visual LANSA for Windows

NO

 

Visual LANSA for Linux

NO

 

 

 

Arguments

No

Type

Req/ Opt

Description

Min Len

Max Len

Min Dec

Max Dec

1

A

Req

Impact List name from which entries are to be retrieved.

7

7

 

 

1

A

Req

Start positioning value consisting of Entry type and Entry Name. The returned list starts with the first entry from the Impact List which is greater than the value passed in this argument.

Entry types are :
DF (field), FD (file),
PF (function), SV (system variable), MT (multilingual text)

Entry names are :
Field - field name
File - file name and library
Function - process and function names
System variable name
Multilingual variable name.

1

22

 

 

 

 

Return Values

No

Type

Req/ Opt

Description

Min Len

Max Len

Min Dec

Max Dec

1

L

Req

Working list to contain Entry information. The calling RDML function must provide a working list with an aggregate entry length of exactly 70 bytes.

Each returned list entry is formatted as follows:

From - To   Description

1 - 2   ENTRY TYPE

      DF = field

      FD = file

      PF = function

      SV = system variable

      MT = multilingual variable

3 - 22   ENTRY NAME

      Field
3 - 12   Field name
13 - 22   Blank

      File

3 - 12   File name

13 - 22   Library

Function

3 - 12   Process name

13 - 19   Function name

20 - 22   Blank

 

      System variable

3 - 22   Variable name

 

      Multilingual Variable

3 - 22   Variable name

23 - 62   DESCRIPTION

63 - 70   << FUTURE EXPANSION>>

 

 

 

 

2

A

Opt

Last entry in returned list Typically this value is used as the positioning argument on subsequent calls to this Built-In Function.

1

22

 

 

3

A

Opt

Return code.

OK = list returned partially or completely filled with Impact List entry details. No more entries exist beyond those returned in the list.

OV = list returned completely filled, but more entries than could fit in the list exist.

NR = list was returned empty. Last entry in the list is returned as blanks.

2

2

 

 

 

 

Example

This function could be used to compile the file entries, which exist in an Impact List. The Impact List would have been created and the file entries added using the LANSA developer's menu option "Work with Impact Lists".

**********    #ETYP  *CHAR 2     
**********    #FILE  *CHAR 10     
**********    #LIB   *CHAR 10     
**********    #DESC  *CHAR 40     
**********    #SPARE *CHAR 8     
**********    #START  *CHAR 22     
**********    #LAST   *CHAR 22     
DEF_LIST      NAME(#ELLST) FIELDS(#ETYP #FILE #LIB #DESC #SPARE)      
              TYPE(*WORKING) ENTRYS(10)      
**********    -Clear list-      
CLR_LIST      NAMED(#ELLST)      
**********    -Request Impact List name-      
REQUEST       FIELDS(#ILNAME) TEXT(('Impact List to use' 5 5))      
**********    -Set the start value to start at the file entries-      
CHANGE        FIELD(#START) TO(FD)      
**********    -Get the entries from the Impact List-      
BEGIN_LOOP     
USE           BUILTIN(GET_ILENTRY_LIST) WITH_ARGS(#ILNAME #START)    
              TO_GET(#ELLST #LAST #RETCOD)      
**********    -If entries found-      
IF            COND('(#RETCOD *EQ OK) *OR (#RETCOD *EQ OV)')      
SELECTLIST    NAMED(#ELLST)      
IF            COND('#TYP = FD')      
USE           BUILTIN(MAKE_FILE_OPERATIONL) WITH_ARGS(#FILE #LIB)  
              TO_GET(#RTN)      
ENDIF                
ENDSELECT            
**********    -If more entries, set start value for repeat -      
IF            COND('#RETCOD *EQ OV')      
CHANGE        FIELD(#START) TO(#LAST)      
ELSE            
RETURN          
ENDIF          
**********     
**********        -No entries-     
ELSE            
RETURN           
ENDIF           
END_LOOP