DQMATCHINFOGET Function

Returns the name of the parse definition that is associated with a match definition.
Valid in: DATA step, PROC SQL, and SCL
Requirement: The specified locale must be loaded into memory as part of the locale list.

Syntax

DQMATCHINFOGET ('match-definition' <,'locale'> )

Required Argument

match-definition
the name of the match definition. The definition must exist in the locale that is used.

Optional Argument

locale
specifies a character constant, variable, or expression that contains the locale name.
Default:The default locale is the first locale in the locale list. If no value is specified, the default locale is used.

Details

The DQMATCHINFOGET function returns the name of the parse definition that is associated with the specified match definition. Obtaining the name of that parse definition enables you to create parsed character values with the DQPARSE or DQPARSETOKENPUT functions.
If the specified match definition does not have an associated parse definition, the DQMATCHINFOGET function returns a missing value.

Example: DQMATCHINFOGET Function

The following example displays the name of the parse definition that is associated with the NAME match definition in the ENUSA locale. That parse definition is then used to display the tokens that are enabled for that parse definition. The tokens are then used to construct a parsed value, create and return a match code, and display the match code.
data _null_;
   parseDefn=dqMatchInfoGet('Name', 'ENUSA');
   tokens=dqParseInfoGet(parseDefn);
   put parseDefn= / tokens=;
run;
data _null_;
   length parsedValue $ 200 matchCode $ 15;
   parsedValue=dqParseTokenPut(parsedValue, 'Joel', 'Given Name', 'Name');
   parsedValue=dqParseTokenPut(parsedValue, 'Alston', 'Family Name', 'Name');
   matchCode=dqMatchParsed(parsedValue, 'Name');
   put matchCode=;
run;