homefeaturesexamplesDOCUMENTATIONblogpricingcontact us
technical documentationCATI documentationcookbookrobot

Displaying different text upon recall of an answer


You want to recall a previous response but display text that is different from the original answer.


Use the ALIAS feature of answer categories and a recall which uses the ALIAS number.


It is sometimes useful to recall a label other than the one displayed originally when asking the question. For example, say you ask the following question:

    Would you qualify this event as
      an accident
      an incident
      Don't know

and you want to the follow-up question to read Was this accident... in the first case, Was this incident... in the second case and Was this event... in the third case.

You could create a second CALCUL question to compute a synonym and recall these labels or you could use the EXECUTE syntax and the Perl ternary operator to display a label conditional to the previous answer. But there is a simpler solution: label aliases.

In the example above, one would code the intial question as follows:

    Would you qualify this event as
    an accident[ALIAS1:accident]
    an incident[ALIAS1:incident]
    Don't know[ALIAS1:event]

and use the following recall in the subsequent question:

    Was this &Q1#1

The &Q1 recalls the answers from Q1 and the #1 states that ALIAS1 must be used. If one category did not possess an ALIAS1, the standard label would be displayed. There can be more than one alias on any given code; the one corresponding to the recall number is displayed.


e-mail technical support!