Profiler Object:Column Specification: Difference between revisions
No edit summary |
No edit summary |
||
(2 intermediate revisions by the same user not shown) | |||
Line 156: | Line 156: | ||
|C=mdProfilerSetColumnScale(profiler, columnNameStr, scaleValue); | |C=mdProfilerSetColumnScale(profiler, columnNameStr, scaleValue); | ||
|.Net=profiler.SetColumnScale(columnNameStr, scaleValue); | |.Net=profiler.SetColumnScale(columnNameStr, scaleValue); | ||
}} | |||
==SetColumnIgnoreOnError== | |||
This feature is not implemented and is reserved for future use. | |||
==GetColumnCount== | |||
This function returns the number of columns been profiled. | |||
{{ Object Syntax | |||
|Syntax=profiler->GetColumnCount(); | |||
|C=Integer = mdProfilerGetColumnCount(profiler); | |||
|.Net=Integer = profiler.GetColumnCount(); | |||
}} | |||
==GetColumnName== | |||
This function returns the name of the column for the given index. | |||
This function takes one parameter. | |||
===Parameters=== | |||
{{ Object Parameters | |||
|Name=Index | |||
|Data Type=Integer | |||
|Description=This is the index number for that particular column. | |||
}} | |||
{{ Object Syntax | |||
|Syntax=profiler->GetColumnName(columnValue); | |||
|C=const char* = mdProfilerGetColumnName(profiler,columnValue); | |||
|.Net=string = profiler.GetColumnName(columnValue); | |||
}} | |||
==GetColumnColumnType== | |||
This function returns a column’s Columns Type in ProfilerColumType form. See [[Profiler Object:Enumeration Listing and Parsing#ProfilerColumnType Enumerations|ProfilerColumnType Enumerations]] for details. You specify the Column Type by using the '''[[Profiler Object:Column Specification#AddColumn|AddColumn]]''' function. | |||
This function takes one parameter. | |||
===Parameters=== | |||
{{ Object Parameters | |||
|Name=ColumnName | |||
|Data Type=String | |||
|Description=Column Name to get the column type. | |||
}} | |||
{{ Object Syntax | |||
|Syntax=profiler->GetColumnColumnType(columnNameStr); | |||
|C=ProfilercolumnType = mdProfilerGetColumnColumnType(profiler,columnNameStr); | |||
|.Net=ProfilerColumnType = profiler.GetColumnColumnType(columnNameStr); | |||
}} | |||
==GetColumnDataType== | |||
This function returns a column’s Data Type in ProfilerDataType form. See [[Profiler Object:Enumeration Listing and Parsing#ProfilerDataType Enumerations|ProfilerDataType Enumerations]] for details. You specify the Data Type by using the '''[[Profiler Object:Column Specification#AddColumn|AddColumn]]''' function. | |||
This function takes one parameter. | |||
===Parameters=== | |||
{{ Object Parameters | |||
|Name=ColumnName | |||
|Data Type=String | |||
|Description=Column Name to get the column’s Data Type. | |||
}} | |||
{{ Object Syntax | |||
|Syntax=profiler->GetColumnDataType(columnNameStr); | |||
|C=ProfilerDataType = mdProfilerGetColumnDataType(profiler, columnNameStr); | |||
|.Net=ProfilerDataType = profiler.GetColumnDataType(columnNameStr); | |||
}} | |||
==GetColumnSize== | |||
This function returns a column’s size. You specify the column size by using the '''[[Profiler Object:Column Specification#SetColumnSize|SetColumnSize]]''' function. | |||
This function takes one parameter. | |||
===Parameters=== | |||
{{ Object Parameters | |||
|Name=ColumnName | |||
|Data Type=String | |||
|Description=Column Name to get the column’s size. | |||
}} | |||
{{ Object Syntax | |||
|Syntax=profiler->GetColumnSize(columnNameStr); | |||
|C=integer = mdProfilerGetColumnSize(profiler, columnNameStr); | |||
|.Net=integer = profiler.GetColumnSize(columnNameStr); | |||
}} | |||
==GetColumnPrecision== | |||
This function returns a column’s precision value. You specify this by using the '''[[Profiler Object:Column Specification#SetColumnPrecision|SetColumnPrecision]]''' function. Use this only on the following ColumnTypes: '''ColumnTypeNumeric''', '''ColumnTypeDecimal''', and '''ColumnTypeCurrency'''. | |||
This function takes one parameter. | |||
===Parameters=== | |||
{{ Object Parameters | |||
|Name=ColumnName | |||
|Data Type=String | |||
|Description=Column Name to get the column’s Precision Value | |||
}} | |||
{{ Object Syntax | |||
|Syntax=profiler->GetColumnSize(columnNameStr); | |||
|C=integer = mdProfilerGetColumnPrecision(profiler, columnNameStr); | |||
|.Net=integer = profiler.GetColumnPrecision(columnNameStr); | |||
}} | |||
==GetColumnScale== | |||
This function returns a column's scale value. You specify this by using the '''[[Profiler Object:Column Specification#SetColumnScale|SetColumnScale]]''' function. Use this only on the following ColumnTypes: '''ColumnTypeNumeric''', '''ColumnTypeDecimal''', and '''ColumnTypeCurrency'''. | |||
This function takes one parameter. | |||
===Parameters=== | |||
{{ Object Parameters | |||
|Name=ColumnName | |||
|Data Type=String | |||
|Description=Column Name to get the column scale value. | |||
}} | |||
{{ Object Syntax | |||
|Syntax=profiler->GetColumnScale(columnNameStr); | |||
|C=integer = mdProfilerGetColumnScale(profiler, columnNameStr); | |||
|.Net=integer = profiler.GetColumnScale(columnNameStr); | |||
}} | |||
==GetColumnValueRangeFrom== | |||
This function returns the lower bound value you set for the column with the [[Profiler Object:Column Specification#SetColumnValueRange|SetColumnValueRange]] function. | |||
This function takes one parameter. | |||
===Parameters=== | |||
{{ Object Parameters | |||
|Name=ColumnNameStr | |||
|Data Type=String | |||
|Description=Column Name to get the lower bound value. | |||
}} | |||
{{ Object Syntax | |||
|Syntax=profiler->GetColumnValueRangeFrom(columnNameStr); | |||
|C=const char* = mdProfilerGetColumnValueRangeFrom(profiler, columnNameStr); | |||
|.Net=string = profiler.GetColumnValueRangeFrom(columnNameStr); | |||
}} | |||
==GetColumnValueRangeTo== | |||
This function returns the upper bound value you set for the column with the [[Profiler Object:Column Specification#SetColumnValueRange|SetColumnValueRange]] function. | |||
This function takes one parameter. | |||
===Parameters=== | |||
{{ Object Parameters | |||
|Name=ColumnNameStr | |||
|Data Type=String | |||
|Description=Column Name to get the upper bound value. | |||
}} | |||
{{ Object Syntax | |||
|Syntax=profiler->GetColumnValueRangeTo(columnNameStr); | |||
|C=const char* = mdProfilerGetColumnValueRangeTo(profiler, columnNameStr); | |||
|.Net=string = profiler.GetColumnValueRangeTo(columnNameStr); | |||
}} | |||
==GetColumnDefaultValue== | |||
This function returns the default value you set for the column with the [[Profiler Object:Column Specification#SetColumnDefaultValue|SetColumnDefaultValue]] function. | |||
This function takes one parameter. | |||
===Parameters=== | |||
{{ Object Parameters | |||
|Name=ColumnNameStr | |||
|Data Type=String | |||
|Description=Column Name to get the default value. | |||
}} | |||
{{ Object Syntax | |||
|Syntax=profiler->GetColumnDefaultValue(columnNameStr); | |||
|C=const char* = mdProfilerGetColumnDefaultValue(profiler, columnNameStr); | |||
|.Net=string = profiler.GetColumnDefaultValue(columnNameStr); | |||
}} | |||
==GetColumnCustomPatterns== | |||
This function returns the tab delimited regular expression validator you added for the column with the [[Profiler Object:Column Specification#SetColumnCustomPattern|SetColumnCustomPattern]] function. This is particularly useful if the profile output file is open on [[Profiler Object:Initialization#SetAppendMode|Report Mode (As set by SetAppendMode)]] and you want to get those patterns if they are set in a previous profiling run. | |||
This function takes one parameter. | |||
===Parameters=== | |||
{{ Object Parameters | |||
|Name=ColumnNameStr | |||
|Data Type=String | |||
|Description=Column Name to get the regular expression. | |||
}} | |||
{{ Object Syntax | |||
|Syntax=profiler->GetColumnCustomPatterns(columnNameStr); | |||
|C=const char* = mdProfilerGetColumnCustomPatterns(profiler, columnNameStr); | |||
|.Net=string = profiler.GetColumnCustomPatterns(columnNameStr); | |||
}} | }} | ||
[[Category:Profiler Object]] | [[Category:Profiler Object]] |
Latest revision as of 18:59, 3 March 2015
You must call AddColumn for each column you intend to profile. All columns must be added before StartProfiling is called.
AddColumn
This function describes a column to be profiled. To successfully profile the data, at least one column should be added. This function accepts three parameters.
Parameters
Name | Data Type | Description |
---|---|---|
ColumnName | String | This is the name of the column to be added. |
ColumnType | Profiler Column Type | This is the type of the column to be added. See ProfilerColumnType Enumerations for details. |
DataType | Profiler Data Type | This is the data type of the column to be added. These are custom data types. See ProfilerDataType Enumerations for details. |
Syntax | profiler->AddColumn(columnNameStr, profilerColumnTYpe, profilerDataType); |
---|---|
C | mdProfilerAddColumn(profiler,columnNameStr,profilerColumntype,profilerDataType); |
.Net | profiler.AddColumn(columnNameStr, profilerColumntype, profilerDataType); |
SetColumnCustomPattern
Optional. This function adds a regular expression validator for a specified column. This can be called multiple times to evaluate different patterns.
This function accepts two parameters.
Parameters
Name | Data Type | Description |
---|---|---|
ColumnNameString | String | Column Name to set the custom pattern. |
RegularExpressionString | String | This is the regular expression to validate the column. |
Syntax | profiler->SetColumnCustomPattern(ColumnNameString, RegularExpressionString); |
---|---|
C | integer = mdProfilerSetColumnCustomPattern(profiler, ColumnNameString, RegularExpressionString); |
.Net | integer = profiler.SetColumnCustomPattern(ColumnNameString, RegularExpressionString); |
SetColumnValueRange
Optional. This SetColumnValueRange function sets the upper and lower bound for the specified column.
This function accepts three parameters.
Parameters
Name | Data Type | Description |
---|---|---|
columnNameStr | String | Column Name to set the value range. |
fromStr | String | Lower bound value. |
toStr | String | Upper bound value. |
Syntax | profiler->SetColumnValueRange(columnNameStr, fromStr, toStr); |
---|---|
C | integer = mdProfilerSetColumnValueRange(profiler, columnNameStr, fromStr, toStr); |
.Net | integer = profiler.SetColumnValueRange(columnNameStr, fromStr, toStr); |
SetColumnDefaultValue
Optional. This function sets the default value to the specified column.
This function takes two parameters
Parameters
Name | Data Type | Description |
---|---|---|
ColumnName | String | Column Name to set the default value. |
DefaultValue | String | This is the default value of the column. |
Syntax | profiler->SetColumnDefaultValue(columnNameStr, defaultValueStr); |
---|---|
C | integer = mdProfilerSetColumnDefaultValue(profiler,columnNameStr,defaultValueStr); |
.Net | integer = profiler.SetColumnDefaultValue(columnNameStr, defaultValueStr); |
SetColumnSize
Optional. This function sets the column size for the specified column.
This function takes two parameters
Parameters
Name | Data Type | Description |
---|---|---|
ColumnName | String | Column Name to set the size. |
ColumnSize | Integer | This is the size of the column. |
Syntax | profiler->SetColumnSize(ColumnNameStr, sizeValue); |
---|---|
C | mdProfilerSetColumnSize(profiler, columnNameStr, sizeValue); |
.Net | profiler.SetColumnSize(columnNameStr, sizeValue); |
SetColumnPrecision
Optional. This function sets the precision for a specified column. This applies to only ColumnTypeNumeric, ColumnTypeDecimal, ColumnTypeCurrency. Precision is the number of digits maximum allowed for that number. This function takes two parameters.
Parameters
Name | Data Type | Description |
---|---|---|
ColumnName | String | Column Name to set the precision Value |
PrecisionValue | Integer | This is the precision value for a specified column. |
Syntax | profiler->SetColumnPrecision(columnNameStr, previsionValue); |
---|---|
C | mdProfilerSetColumnPrecision(profiler, ColumnNameStr, PrecisionValue); |
.Net | profiler.SetColumnPrecision(ColumnNameStr, PrecisionValue); |
SetColumnScale
Optional. This function sets the scale for a specified column. Scale is the number of decimal places (number of digits on the right hand side of the decimal point.) This applies to only ColumnTypeNumeric, ColumnTypeDecimal, ColumnTypeCurrency.
This function takes two parameters.
Parameters
Name | Data Type | Description |
---|---|---|
ColumnName | String | This is the name of the column to be added |
ScaleValue | Integer | This is the scale value for the specified column |
Syntax | profiler->SetColumnScale(columnNameStr, scaleValue); |
---|---|
C | mdProfilerSetColumnScale(profiler, columnNameStr, scaleValue); |
.Net | profiler.SetColumnScale(columnNameStr, scaleValue); |
SetColumnIgnoreOnError
This feature is not implemented and is reserved for future use.
GetColumnCount
This function returns the number of columns been profiled.
Syntax | profiler->GetColumnCount(); |
---|---|
C | Integer = mdProfilerGetColumnCount(profiler); |
.Net | Integer = profiler.GetColumnCount(); |
GetColumnName
This function returns the name of the column for the given index.
This function takes one parameter.
Parameters
Name | Data Type | Description |
---|---|---|
Index | Integer | This is the index number for that particular column. |
Syntax | profiler->GetColumnName(columnValue); |
---|---|
C | const char* = mdProfilerGetColumnName(profiler,columnValue); |
.Net | string = profiler.GetColumnName(columnValue); |
GetColumnColumnType
This function returns a column’s Columns Type in ProfilerColumType form. See ProfilerColumnType Enumerations for details. You specify the Column Type by using the AddColumn function.
This function takes one parameter.
Parameters
Name | Data Type | Description |
---|---|---|
ColumnName | String | Column Name to get the column type. |
Syntax | profiler->GetColumnColumnType(columnNameStr); |
---|---|
C | ProfilercolumnType = mdProfilerGetColumnColumnType(profiler,columnNameStr); |
.Net | ProfilerColumnType = profiler.GetColumnColumnType(columnNameStr); |
GetColumnDataType
This function returns a column’s Data Type in ProfilerDataType form. See ProfilerDataType Enumerations for details. You specify the Data Type by using the AddColumn function.
This function takes one parameter.
Parameters
Name | Data Type | Description |
---|---|---|
ColumnName | String | Column Name to get the column’s Data Type. |
Syntax | profiler->GetColumnDataType(columnNameStr); |
---|---|
C | ProfilerDataType = mdProfilerGetColumnDataType(profiler, columnNameStr); |
.Net | ProfilerDataType = profiler.GetColumnDataType(columnNameStr); |
GetColumnSize
This function returns a column’s size. You specify the column size by using the SetColumnSize function.
This function takes one parameter.
Parameters
Name | Data Type | Description |
---|---|---|
ColumnName | String | Column Name to get the column’s size. |
Syntax | profiler->GetColumnSize(columnNameStr); |
---|---|
C | integer = mdProfilerGetColumnSize(profiler, columnNameStr); |
.Net | integer = profiler.GetColumnSize(columnNameStr); |
GetColumnPrecision
This function returns a column’s precision value. You specify this by using the SetColumnPrecision function. Use this only on the following ColumnTypes: ColumnTypeNumeric, ColumnTypeDecimal, and ColumnTypeCurrency.
This function takes one parameter.
Parameters
Name | Data Type | Description |
---|---|---|
ColumnName | String | Column Name to get the column’s Precision Value |
Syntax | profiler->GetColumnSize(columnNameStr); |
---|---|
C | integer = mdProfilerGetColumnPrecision(profiler, columnNameStr); |
.Net | integer = profiler.GetColumnPrecision(columnNameStr); |
GetColumnScale
This function returns a column's scale value. You specify this by using the SetColumnScale function. Use this only on the following ColumnTypes: ColumnTypeNumeric, ColumnTypeDecimal, and ColumnTypeCurrency.
This function takes one parameter.
Parameters
Name | Data Type | Description |
---|---|---|
ColumnName | String | Column Name to get the column scale value. |
Syntax | profiler->GetColumnScale(columnNameStr); |
---|---|
C | integer = mdProfilerGetColumnScale(profiler, columnNameStr); |
.Net | integer = profiler.GetColumnScale(columnNameStr); |
GetColumnValueRangeFrom
This function returns the lower bound value you set for the column with the SetColumnValueRange function.
This function takes one parameter.
Parameters
Name | Data Type | Description |
---|---|---|
ColumnNameStr | String | Column Name to get the lower bound value. |
Syntax | profiler->GetColumnValueRangeFrom(columnNameStr); |
---|---|
C | const char* = mdProfilerGetColumnValueRangeFrom(profiler, columnNameStr); |
.Net | string = profiler.GetColumnValueRangeFrom(columnNameStr); |
GetColumnValueRangeTo
This function returns the upper bound value you set for the column with the SetColumnValueRange function.
This function takes one parameter.
Parameters
Name | Data Type | Description |
---|---|---|
ColumnNameStr | String | Column Name to get the upper bound value. |
Syntax | profiler->GetColumnValueRangeTo(columnNameStr); |
---|---|
C | const char* = mdProfilerGetColumnValueRangeTo(profiler, columnNameStr); |
.Net | string = profiler.GetColumnValueRangeTo(columnNameStr); |
GetColumnDefaultValue
This function returns the default value you set for the column with the SetColumnDefaultValue function.
This function takes one parameter.
Parameters
Name | Data Type | Description |
---|---|---|
ColumnNameStr | String | Column Name to get the default value. |
Syntax | profiler->GetColumnDefaultValue(columnNameStr); |
---|---|
C | const char* = mdProfilerGetColumnDefaultValue(profiler, columnNameStr); |
.Net | string = profiler.GetColumnDefaultValue(columnNameStr); |
GetColumnCustomPatterns
This function returns the tab delimited regular expression validator you added for the column with the SetColumnCustomPattern function. This is particularly useful if the profile output file is open on Report Mode (As set by SetAppendMode) and you want to get those patterns if they are set in a previous profiling run.
This function takes one parameter.
Parameters
Name | Data Type | Description |
---|---|---|
ColumnNameStr | String | Column Name to get the regular expression. |
Syntax | profiler->GetColumnCustomPatterns(columnNameStr); |
---|---|
C | const char* = mdProfilerGetColumnCustomPatterns(profiler, columnNameStr); |
.Net | string = profiler.GetColumnCustomPatterns(columnNameStr); |