Creating a DQS Plan Using the Data Quality Metric Step

How to:

This section describes how to create a text file using a DQS plan with the Data Quality Metric step.


Top of page

x
Procedure: How to Create a DQS Plan Using the Data Quality Metric Step

To create a DQS plan:

  1. Double-click the dqs.exe file to open iWay Data Quality Server (DQS).

    If you have not installed iWay DQS, perform the following steps:

    • Unzip the iWay DQS archive file to a local drive on your system.
    • Copy the license file to the following directory:
      [iWayDQSHOME]\runtime\license_keys

      Note: The location on your file system where the DQS archive file is extracted to is referred as [iWayDQSHOME].

    • For your reference, all iWay DQS projects are stored in the following directory by default:
      [iWayDQSHOME]\workspace
  2. Click OK to accept the license agreement.

    iWay DQS opens, as shown in the following image.

  3. In the File Explorer tab, right-click DQ Projects, select New, and then click Project.

    The Create New Project dialog box is displayed.

  4. Enter the project name (for example, Metrics) in the Name field.
  5. Select the Project from template option, accept the default template that is selected (SimpleProject), and then click Finish.

    The new project (for example, Metrics) is listed below the DQ Projects node in the File Explorer tab, as shown in the following image.

    The Data_Profiling project contains the following folder structure:

    • bin. Contains the actual DQS plan.
    • data. Contains the data files that are required and produced by the DQS plan. It contains the following subfolders:
      • ext. Contains the following subfolders related to the creation of lookup files:
        • build. Contains the input files to the DQS plans.
        • lkp. Contains the log files produced by the DQS plans.
        • src Contains the output files produced by the DQS plans. This folder also contains a reports subfolder.
    • in. Contains the input files to the DQS plans.
    • out. Contains the output files produced by the DQS plans.
    • pro. Contains the profile files produced by the DQS plans.

    Note: This standard folder structure is created by iWay DQS for easy organization. Any number of folders and subfolders can be added if required.

  6. In the bin folder, rename Main.plan to Airlines_Quality.plan, as shown in the following image.

  7. Double-click Airlinejan2010.txt (placed in the in folder) to view the existing text file, as shown in the following image.

  8. Right-click the text file (Airlinejan2010.txt) and select Edit Metadata.

    The Edit File Metadata dialog box opens, as shown in the following image.

  9. Edit the metadata of the text file as shown.
  10. Drag and drop the text file (Airlinejan2010.txt) in the Airlines_Quality.plan workspace area.

    Note: The input file can consist of different formats, for example, an Excel spreadsheet, various databases, and so on. For more information, see the iWay Data Quality Server Reference Guide.

  11. Double-click the Text File Reader step to view the properties.

    The File Name field specifies the name and location of the input text file (../data/in/Airlinejan2010.txt), as shown in the following image.

  12. Drag and drop the Data Quality Indicator step, which is available in the Analyze category on the right pane.

  13. Create a connection from the Text File Reader step to the Data Quality Indicator step using the Connection object, which is also located on the right pane.
  14. Double-click the Data Quality Indicator step.

    The Data Quality Indicator step properties dialog box opens, as shown in the following image.

  15. Enter a name in the Explained Column field and click Create to create a shadow column in the Text File Reader step.
  16. Select one of the Out Records Filter type.

    Note: Explained Column and Out Records Filter type have no effect on the summary text file that is going to be produced for iWay Data Profiler. It is related to the overall output, which is going to be discarded. You must specify those fields since it is required.

  17. In the left pane, select Rules and click Add to add any number of rules by specifying the following:
    • Name (Required)
    • Code (Required)
    • Short Description (Optional, will not be displayed in iWay Data Profiler)
    • Description (Optional)
    • Expression (Required, to check the quality of data)

    For example:

    Note: Do not press Enter while entering values in the Expression and Description fields. In addition, do not use single quote (') and double quote (“) characters in the expression.

  18. Drag and drop the Trash step from the Output tab in the right pane (to discard the overall output) to the workspace area.

  19. Connect the output end of the Data Quality Indicator step to the Trash step.
  20. Drag and drop the Text File Writer step from the Output tab in the right pane and connect the summary of the Data Quality Indicator to the Text File Writer step.

  21. Double-click the Text File Writer step to configure the required properties, as shown in the following image.

    The File Name field specifies the location of the output text file (../data/out/DQIAirlineJan2010_Report.txt), which is generated by running the DQIAirlineJan2010 plan (Airlines_Quality.plan). The output file is created under the bin folder.

  22. Provide the following required information:
    • Field Separator: ;$
    • Select the Write Header and Write All Columns options.
    • String Qualifier: ~@
    • String Qualifier Escape: Leave blank
    • Select the Use String Qualifier on All Columns option.

    Note: Leave the default values for the remaining options.

  23. Click OK.
  24. Select and run the DQIAirlineJan2010 plan (Airlines_Quality.plan) by clicking the Run icon or by pressing Ctrl+F11.
  25. Right-click the out folder in the left pane and click Refresh to view the output file, DQIAirlineJan2010_Report.txt.

    Note: The out folder is located under the data folder, in the metric project folder structure.

  26. Double-click the DQIAirlineJan2010_Report.txt file that was generated by the Airlines_Quality.plan, as shown in the following image.


iWay Software