NIPO ODIN Version 5.17
*ADDRESS
Purpose
Refers to a data field in the T-file or Sample table record.
Syntax
*ADDRESS
Description
This command is always used in combination with *QUESTION and a question type definition and must be specified after these commands on the same line. With this command you can refer to a data field in the T-file or Sample table record. This data field specification must have a fixed (non-variable) format.
Remarks
- When using a Sample table, the NIPO ODIN questionnaire can refer to all Sample table field names by using the
*SAMPLEDATA command. However you can also refer to positions in a Sample table by referencing field positions as if it was a T-file, because the fields in the Sample table are mapped to the default positions in T-files see Sample table (separate table for each survey) for details. - You can refer to positions in the T-file that overlap fields in a Sample table, but the result is truncated at the border of the field. A syntax check will warn of such truncations with an error message such as
Warning: 136L55 spans multiple database fields, will be truncated to 136L45 .
Example
*QUESTION 1 *NUMBER 290L2 *ADDRESS
*QUESTION 2 *NUMBER 61L2 How old are you?
*MOVA Q1 Q2
This example stores the contents of question 2 (position 61-62) into position 290-291 of the T-file or Sample table record.
Example 2
*QUESTION 11 *ALPHA 61L17 *MOVU Q11 1L17
This transfers the field TelephoneNumber from the Sample table into Q11. This may also be done using:
*QUESTION 11 *ALPHA 61L17 *SAMPLEDATA TelephoneNumber *COPY Q11 "*?TelephoneNumber"
The telephone number is an alpha-numerical field, because it may contain spaces and a leading zero.
Example 3
*QUESTION 12 *NUMBER 81L8 *MOVU Q12 36L8
This copies the contents of the field InterviewerNumber from the Sample table into Question 12, because 36L8 corresponds to the InterviewerNumber field in the Sample table. This may also be done using:
*QUESTION 12 *ALPHA 81L8 *SAMPLEDATA InterviewerNumber *COPY Q12 [InterviewerNumber]
|