Creating Custom From Clauses

Custom From clauses are an advanced feature for users who are comfortable creating their own SQL logic.SQR Production Reporting Studio uses the SQL code that you enter to define the From Clause in the query SQL. Note that SQR Production Reporting Studio does not do any error checking. Only users who are interested in creating specialized SQL logic should use this feature.  

*  To create a custom From clause:

  1. Click From on the Query Builder - Fields page.

    The Custom From Clause Builder is displayed.

  2. Select Use Custom From Clause.

  3. Enter the SQL code.

    For example, you could create a From clause to print a report if the number of customers is greater than 50. In this example, you would enter:

    customers where cust_num > 50
  4. To read a text file into the input area, enter the name of the file next to Load from text file.

  5. To overwrite the From clause with the last selected file, click Reload.

    This feature is useful if you made a lot of edits on the From clause and want to get back to the original From clause before you made any edits.

  6. Click OK to close the Custom From Clause Builder.

    Caution!

    Using this feature causes user-defined Where clauses or Having clauses to be ignored when Production Reporting code is generated.