Required Parameter Group: | |||
1 | Qualified database file name | Input | Char(20) |
2 | Input string | Input | Char(*) |
3 | Length of input string | Input | Binary(4) |
4 | Response variable | Output | Char(*) |
5 | Length of response variable | Input | Binary(4) |
6 | Length of response available | Output | Binary(4) |
7 | Response code | Output | Binary(4) |
8 | Error Code | I/O | Char(*) |
The QtmhCvtDB API provides an interface for CGI programs to parse CGI input, defined as a series of keywords and their values, into a buffer which is formatted according to a DDS file specification. CGI input data, which comes to the CGI program as character data, will be converted by the QtmhCvtDB API to the data type defined for the keyword by the corresponding field name in the input DDS file. Language statements, such as the ILE C #pragma mapinc statement, provide the ability to map the returned structure with field names defined in the DDS file. See the appropriate language user’s guide for details.
The following DDS field types are handled:
The following DDS field types are not handled:
The input variable containing the name of the database file defining field names and data types for the keywords anticipated in the input to the CGI program. Typically, the database file is generated using DDS to define the fields corresponding to the keywords anticipated in the CGI inputs. The first 10 characters contain the database file name, and the second 10 characters contain the library name.
The input variable containing the string of CGI input parameters to be parsed. When the environment variable REQUEST_METHOD indicates that the method is GET, characters up to the first ? are ignored. The string must meet the format requirements for CGI input keyword strings.
The input variable containing the length of the character string that contains the CGI input parameters to be parsed. The length of the string must be greater than 0.
The output variable which is to contain the structure mapped according to the database file describing the input parameters anticipated by the CGI program.
The input variable containing the total length of the buffer into which the CGI input parameters will be parsed.
The output variable that contains the length of the response. If the response variable is too small to contain the entire response, this parameter will be set to the size that is required to contain the entire response.
A code that indicates the status of the request.
The structure in which to return error information. For the format of the structure and for details on how to process API errors, see the API error reporting topic in the iSeries™ Information Center.