| Functions and CALL Routines |
Returns the name of the parse definition that is associated with
the specified gender definition.
| Valid in: |
DATA step, PROC SQL, or SCL
|
|
DQGENDERINFOGET('gender-analysis-definition' <, 'locale'>)
|
- gender-analysis-definition
-
specifies the name of the gender analysis definition. .
| Restriction: |
must exist in the specified locale. |
- locale
-
(optional) specifies the name of the locale that contains
the specified gender analysis definition. The value can be a name in quotation
marks, the name of a variable whose value is a locale name, or an expression
that evaluates to a variable name or to a quoted locale name.
The specified locale must be loaded into memory as part of the locale
list.
| Default: |
the first locale in the locale list |
| Restriction: |
if no value is specified, the default
locale is used. |
| See |
Load and Unload Locales. |
The following example displays the parse definition that is associated
with the gender analysis definition in the ENUSA locale called GENDER. The
parse definition that is returned is then used to display the names of the
tokens that are enabled for that parse definition. The tokens are then used
to construct a parsed value and return a match code for that parsed value.
/* display the parse definition associated with the */
/* GENDER definition and display the tokens in that */
/* parse definition. */
data _null_;
parseDefn=dqGenderInfoGet('Gender', 'ENUSA');
tokens=dqParseInfoGet(parseDefn, 'ENUSA');
put parseDefn= / tokens=;
run;
/* build a parsed value from two tokens and display */
/* in the log the gender determination for that value. */
data _null_;
length parsedValue $ 200 gender $ 1;
parsedValue=dqParseTokenPut(parsedValue, 'Sandi', 'Given Name', 'Name');
parsedValue=dqParseTokenPut(parsedValue, 'Baker', 'Family Name', 'Name');
gender=dqGenderParsed(parsedValue, 'Gender');
put gender=;
run;
Copyright © 2009 by SAS Institute Inc., Cary, NC, USA. All rights reserved.