Setting up SQL Query Exports

Use the steps to set up an SQL Query Export.

To display the hidden fields, see the steps in Displaying the hidden CSV Query Export parameters.

  1. Specify this information to create a scheduled task in the Job Scheduler:
    Task Type
    Export Task (CSV Query)

    Use the SQL Query Export Interface to perform an SQL query on application tables and export the results to a comma separated value (CSV) or a fixed width text file.

  2. Configure these parameters for the (CSV Query) Export Task Parameters task type:
    SQL Query
    Specify the SQL query to run.
    File Name
    Specify the path and file name to be exported, using the absolute path with respect to the Job Scheduler or file server.
    Disable enclosing in double quotes
    Select the check box to disable double quotes in the CSV file.
    Note: This option is hidden by default.
    Delimiter
    Provide a delimiter or accept the default value (comma delimited).
    Note: This option is hidden by default.
    Add Date and Time to Each File Name
    Optionally, select this check box to append the date and time to the export file. The format is: Filename_yyyyMMdd_HHmmss.txt.
    Performs Difference

    Optionally, select this check box to have the export task perform a difference between the current SQL query results and the last SQL query results of the same Export Task (CSV Query) task. Only the information that is different is written to the new SQL query CSV file.

    When you run the initial export task, the application creates two directories: /compare and /new. These directories reside in the same location of the exported output file. For each running of the same export task, the new exported file is placed in the /new directory and is compared with the file in the /compare directory (if any exists). The resulting difference file is placed in the main folder.

    The file in the /new directory is copied to the /compare directory for future runs of the same export task.

    Do not generate file if no differences
    Optionally, select this check box to have the export task skip generating a difference file when no changes are detected between the current SQL query results and the last SQL query results of the same Export Task (CSV Query) task.
    Note: To verfiy that the task detected no differences, view the Job Scheduler log for the message "Task ran successfully, no differences were found and no file was created."