Control Language (CL) for iSeries is supported in the Mainframe dependencies group. Links from a CL file (multiple extensions are supported, e.g. CL, CLLE, etc.) to other files are detected following the statements listed below:
The call to CALL or CALL PGM or CALLPGM implies a dependency on a .CL or a .RPG file.
CALL fileCALL "file"CALL PGM(file)CALL PGM("file")CALLPGM(file)CALLPGM("file")CALL(path)CALL PGM(path)CALLPGM(path)Where file is the name of a CL or RPG file in the project and path is a combination of library and file like *LIBL/file, *CURLIB/file and LIBNAME/file *LIBL – Search for the target file name in all libraries and establish the dependency with all matches *CURLIB – Search for the target file name from the root of the source file path and dependency link will be formed for the matched target LIBNAME – Search for the folder named LIBNAME from the root of the source file path and get the list of matched target files
In case, LIBNAME is not found during the analysis, then Missing library node named LIBNAME is created
Also, to address this file, you can also use an explicit path notation (no relative path like ../my/parent/file). If no file corresponds to the path, we will mark it as a missing one.
The call to CALLPRC PRC implies a dependency on all kind of file except .CPY.
CALLPRC PRC(file)CALLPRC PRC('file')CALLPRC PRC("file")Where file is the name of a non-CPY file in the project.
To address this file, you can also use an explicit path notation (no relative path like ../my/parent/file). If no file corresponds to the path, we will mark it as a missing one.
Along with the file, CALLPRC PRC command also map to the global procedure
CALLPRC PRC(procedure-name)Where procedure-name is the global procedure defined in the file like sqlrpgle. Refer to procedure declaration statement.
The call to CLRPFM implies a dependency on an existing .CL file.
CLRPFM cl_fileCLRPFM +cl_fileWhere cl_file is the name of a CL file in the project.
The reference to a DTAARA implies a dependency on a DTAARA object. It can be used along with RTVDTAARA, CHGDTAARA and CRTDTAARA commands.
RTVDTAARA DTAARA(MYDATAOBJECT)RTVDTAARA DTAARA(path/to/MYDATAOBJECT)RTVDTAARA DTAARA(&MYDATAVAR) where &MYDATAVAR is a variaable referencing a DTAARA object.Where MYDATAOBJECT is the name of a DTAARA object in the project.
The call to FILE implies a dependency on an existing .CL file.
FILE(cl_file)Where cl_file is the name of a CL file in the project.
Using this FILE property will not create any dependency when used with CRTSRCPF or DSPFD commands :
CRTSRCPF FILE(cl_file)DSPFD FILE(cl_file)The call to FROMFILE implies a dependency on an existing .CL file.
FROMFILE(cl_file)Where cl_file is the name of a CL file in the project.
The call to OPNID implies a dependency on an existing .CL file.
OPNID(cl_file)Where cl_file is the name of a CL file in the project.
The call to RQSDTA implies a dependency on a .CL or a .RPG file.
RQSDTA('CALL file')Where file is the name of a CL or RPG file in the project.
The call on RUNSQL SQLSTM is used to execute an SQL query. Check the SQL dependencies for more details.
RUNSQL SQLSTM('QUERY')Where QUERY is an SQL query.
The call to SNDPGMMSG implies a dependency on a .MSGF file.
SNDPGMMSG MSGID(&ERRORID) MSGF(MESSAGEFILE)SNDPGMMSG MSGID(&ERRORID) MSGF(*LIBL/MESSAGEFILE)Where SNDPGMMSG is the name of a MSGF file in the project.
The call to SCRMBR implies a dependency on a .CL file.
SRCMBR(cl_file)Where cl_file is the name of a CL file in the project.
We can define temporary object with OVRPRTF, OVRBDF and CRTPF statements which behave like an alias of an external file. Other programs can use this object to refer to the source file.
CL_FILE.cl
OVRPRTF FILE(MY_ALIAS) TOFILE(MY_FILE)
CALL PGM(RPG_FILE)
DLTOVR FILE(MY_ALIAS)
CRTPF FILE(MY_FILE) SRCFILE(MY_ALIAS)
CALL PGM(RPG_FILE)
DLTOVR FILE(MY_ALIAS)RPG_FILE.rpgle
FMY_ALIAS IF E K DISKIn this example, we create the temporary object MY_ALIAS as an alias of MY_FILE. Then RPG_FILE call this object through an F line which implies a dependency between RPG_FILE and MY_FILE. OVRPRTF and OVRBDF have same patterns, CRTPF have different keywords.
The call to TOFILE implies a dependency on an existing .CL file.
TOFILE(cl_file)Where cl_file is the name of a CL file in the project.