Table of Contents

Search

  1. Preface
  2. PowerExchange Navigator Introduction
  3. Data Maps
  4. Data Maps for Specific Data Sources
  5. Copybooks
  6. Registration Groups and Capture Registrations
  7. Extraction Groups and Extraction Maps
  8. Personal Metadata
  9. Database Row Test
  10. PowerExchange Navigator Examples
  11. Appendix A: PowerExchange Functions for User-Defined Fields
  12. Appendix B: User Access Method Programs
  13. Appendix C: Application Groups and Applications
  14. Appendix D: Data Map Properties
  15. Appendix E: Record, Field, and Table Properties
  16. Appendix F: DTL__CAPXTIMESTAMP Time Stamps
  17. Appendix G: Trace for Creating a Memory Map When Importing a COBOL Copybook

Navigator User Guide

Navigator User Guide

CallProg

CallProg

Calls a user-defined program or subroutine to process the source data in a record.
Syntax:
[
result
=]CallProg('
program
','
subroutine
','
linkage
'[,
arg1
][,
arg2
][,
...
])
The parameters are:
  • result
    . Optional. NUM32. This argument contains the return value from program called by the CallProg function, which is one of the following values:
    • 0
      . Success.
    • Non-zero
      . Failure.
      If you do not specify a result argument and a non-zero return code is returned from the external program, CallProg executes the following default map-level error responses:
    • Ends the extract.
    • Skips this subroutine.
  • program
    . The name of the program that contains the subroutine. Depending on the operating system, the program is one of the following:
    • i5/OS
      . A service program.
    • Linux or UNIX
      . A shared object.
    • Windows
      . A DLL.
    • z/OS
      . A load module.
      Enclose the program name in single quotes.
  • subroutine
    . The name of the entry point in the program. Depending on the operating system, the subroutine is one of the following:
    • i5/OS
      . The subroutine name.
    • Linux, UNIX, or Windows
      . The subroutine name.
    • z/OS for Assembler, C, or COBOL
      programs
      . You must provide a value, but the value is ignored and the default entry point for the load module is used. Specify the same name as the program.
    • z/OS for PL/I programs
      . If multiple fetchable subroutines reside in the same load module, specify the subroutine name.
      Enclose the subroutine name in single quotes.
  • linkage
    . The type of linkage, which determines the way that arguments are passed to and return codes are returned from the program or subroutine.
    The following table describes each linkage type:
    Linkage Type
    Supported Operating Systems
    Arguments
    Returns
    C
    • i5/OS
    • Linux, UNIX, and Windows
    • z/OS
    Passed through the stack
    Program return code
    COBOL
    z/OS
    Passed as a list of addresses
    Address of failure code integer
    OS
    z/OS
    Passed as a list of addresses
    Program return code
    OS400
    i5/OS
    Passed as a list of addresses
    Address of failure code integer
    PLI
    z/OS
    Passed as a list of addresses
    Address of failure code integer
    Enclose the linkage type in single quotes.
  • [,
    arg1
    ][,
    arg2
    ][,
    ...
    ]. One or more optional arguments passed to the program or subroutine.

0 COMMENTS

We’d like to hear from you!