The programs uploaded to the user environment follow a certain IO model depending on the STYLE clause of the APPLY table operator.
The APPLY table operator has a STYLE clause that defines the I/O protocol between the User Process (the process started using the APPLY_COMMAND) and the database. When the STYLE clause has a value of "CSV", the User Process must write output rows to stdout or stderr and reads rows from stdin. A process uses stdout to return rows back to the database and uses stderr to return debugging information that can be output from the APPLY table operator when the APPLY_COMMAND exits with a non-zero exit code.
Data is formatted as csv when reading from stdin and writing to stdout based on RFC4180 but deviates in the following ways:
- A QUOTECHAR other than a double quote may be used.
- A DELIMITER other than comma may be used.