Profiler Object:Order of Operations: Difference between revisions

From Melissa Data Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 1: Line 1:
[[Profiler Object:Reference|← Profiler Object Reference]]
{{ProfilerIntroductionNav}}
 
{| class="mw-collapsible" cellspacing="2" style="background-color:#f9f9f9; border:1px solid #aaaaaa; font-size:9pt; color:#0645ad; padding:8px 8px;"
! style="text-align:left; color:black; border-bottom:1px solid #aaaaaa;"|'''Profiler Object Navigation'''
|-
| style="padding-right:220px;"|
|-
|[[Profiler Object:Introduction|Introduction]]
|-
|[[Profiler Object:System Requirements|System Requirements]]
|-
|[[Profiler Object:Licensing|Licensing]]
|-
|[[Profiler Object:Order of Operations|Order of Operations]]
|}





Revision as of 00:12, 3 March 2015

← Profiler Object Reference

Profiler Object Navigation
Introduction
System Requirements
Licensing
Order of Operations
Using Append Mode
Using Report Mode



1. Create an instance of the Profiler object.

Create profiler as New Instance of mdProfiler

2. Set path to the profiler data files.

CALL SetPathToProfilerDataFiles WITH DataPath

3. Call the SetFilename function to set the ouput file.

CALL SetFileName WITH OutputFile

4. Call the SetLicenseString function to set the license string. This was supplied by your Melissa Data Representative.

CALL SetLicenseString WITH LicenseString

5. Configure the profiler object by setting these functions. These are not mandatory.

CALL SetSortAnalysis WITH SortAnalysisValue
CALL SetMatchUpAnalysis WITH MatchUpAnalysisValue
CALL SetRightFielderAnalysis WITH RightfielderAnalysisValue
CALL SetDataAggregation WITH DataAggregationValue

6. These setting are optional.

CALL SetUserName WITH UserNameString
CALL SetTableName WITH TableNameString
CALL SetJobName WITH JobNameString
CALL SetJobDescription WITH JobDescriptionString

7. Call the InitilializeDataFiles function to connect the Profiler Object to its supporting data file.

CALL InitializeDataFiles RETURNING Result
  IF Result IS 0 THEN
    CALL GetBuildNumber Returning BuildNumber
    CALL GetDatabaseDate Returning DBExpireDate
    CALL GetLicenseExpirationDate Returning LicenseExpireDate
  ELSE
    CALL GetInitializeErrorString Returing ErrorString
    Print ErrorString
  END IF

8. Add the columns to the table mentioned above.

CALL AddColumn WITH ColumnNameString, ColumnType, DataType

9. Configure the Column by setting the following functions. These are not mandatory.

CALL SetCustomPattern WITH ColumnName, RegularExpression RETURNING Int
CALL SetValueRange WITH ColumnName, FromString, ToString RETURNING Int
CALL SetDefaultValue WITH ColumnName, ValueString RETURNING Int
CALL SetColumnSize WITH ColumnName, SizeValue 
CALL SetColumnPrecision WITH ColumnName, PrecisionValue
CALL SetColumnScale WITH ColumnName, ScaleValue

10. Initiate profiling by calling StartProfiling function.

CALL StartProfiling

11. Loop through the input data file lines and set the column values.

WHILE ReadingInputLines 
  FOREACH Column column in InputLine
    CALL SetColumn WITH column.Name, column.Value
    CALL AddRecord RETURNING ResultCodesString
    CALL GetResults WITH column.Name RETURNING ResultCodes
  END LOOP

12. CALL ProfileData function to do profiling for data aggregations.

CALL ProfileData

13. CALL the list of required functions to get the profiled values. These functions have been categorized into three different sections: table, column, and iterator get funtions.

For example:

CALL GetColumnMostPopularCount WITH ColumnName RETURNING Int
CALL GetTableRecordCount RETURNING Int