Data.Column.Check
Top  Previous  Next


Checks that the text in a column of the [Data] section contains valid characters and has valid length

This command is useful after new data is imported (by a Data.Load or a $GetDataFiles command or manually) to make sure that all data is valid before the batch job begins.

Category
Data section

Script section
[Init]

Data.Column.Check Column, Type [,Characters, MinLen, MaxLen]

Column
Column number of column in [Data] section to check  

Type

Specifies check type, see table 1 below  

Characters

Valid characters or valid words  

MinLen

Minimum length (0=no check)  

MaxLen

Maximum length (0=no check)  

Table 1 - Type parameter
Option
Characters
MinLen
MaxLen
Description
SamDescription
NU*
NU*
NU*
Predefined, SC*. MinLen = 0, MaxLen = 48 (Account and group descriptions etc.)
SamName
NU*
NU*
NU*
Predefined, SC*. MinLen = 1, MaxLen = 20. (Account and group names etc.)
SamPassword
NU*
NU*
NU*
Predefined, SC*. MinLen = 0, MaxLen = 14
User_FixedWord
Words separated by the "§" character.
NU*
NU*
User defined - only the listed words are valid. Unlike the other types, this one is not case sensitive.
User_ChrLen
Permitted characters
Minimum length
Maximum length
User defined - only strings of the specified length containing the specified characters are valid

NU* = Not Used
SC* = Standard Character Set + AddToValidCharSet characters

Examples
1) Check account names in column 2

Data.Column.Check 2, SamName

2) Check strings in column 5, valid strings = "finance" and "customers"

Data.Column.Check 5, User_FixedWord, finance§customers§

3) Check strings in column 6, valid characters = "abcdefghij", minimum length = 5, maximum length = 10

Data.Column.Check 6, User_ChrLen, abcdefghj, 5, 10