More Detail on Boolean (True/False) Functions
Top  Previous  Next

Some functions in SSI Web are Boolean (true/false) functions that do not return a specific "value". They simply evaluate to true or false. You can use the syntax "not" prior to the Boolean function (as shown in the examples below).



ANSWERED

ANSWERED is true if the question was answered by the respondent. Note that ANSWERED evaluates to false if the respondent did not ever see the question (use SHOWN if you are interested in whether the question was seen). (Note: check-box questions are an exception to these rules; check-box questions, if ever displayed to the respondent are always considered "answered," with a value of 1 or 0.)

The format is:

   Answered(QuestionName)

For example, you may specify a skip in SSI Web that executes if the following is true:

   Answered(Q1)

In other words, skip if Q1 was answered by the respondent. You could also execute a skip if Not Answered(Q1), which would execute if Q1 was not answered.



ISNUMBER

ISNUMBER is true if the entire string is made up of numeric values (0 to 9), false otherwise. For example, the string "01605" contains only numeric characters.

The format is:

   IsNumber(QuestionName)

For example, you may specify a skip in SSI Web that executes if the following is true:

   IsNumber(Q1)

In other words, skip if the respondent's answer to Q1 contains only numbers. You could also execute a skip if not IsNumber(Q1), which would execute if Q1 contained characters other than numbers 0 to 9.



JAVASCRIPT

JAVASCRIPT is true if the respondent's browser has JavaScript 1.2 enabled (and you have turned on JavaScript use under Global Settings), false otherwise.

The format is:

   JavaScript( )

For example, you may specify a skip in SSI Web that executes if the following is true:

   JavaScript( )

In other words, skip if the respondent's system has JavaScript enabled. You could also execute a skip if not JavaScript( ), which would execute if the respondent's system did not have JavaScript enabled.



LISTHASPARENTMEMBER

LISTHASPARENTMEMBER is true if the specified parent member exists in the specified list, false otherwise.

The format is:

   ListHasParentMember(ListName, ParentMember#)

For example, you may specify a skip in SSI Web that executes if the following is true:

   ListHasParentMember(BrandAwareList, 12)
   
In other words, skip if the constructed list named BrandAwareList contains item #12 (from the original predefined parent list for BrandAwareList). You could also execute a skip if not ListHasParentMember(BrandAwareList, 12), which would execute if the BrandAwareList did not contain item #12.



SHOWN

SHOWN is true if the question was seen by the respondent, or false if the question was not seen by the respondent.


The format is:

   Shown(QuestionName)

For example, you may specify a skip in SSI Web that executes if the following is true:

   Not Shown(Q1)
   
In other words, skip if Q1 was not seen by the respondent. You could also execute a skip if Shown(Q1), which would execute if Q1 was seen by the respondent (even if it was not answered).

Note: for questions such as multi-select, constant sum, Free Format questions and grid questions, the full variable name must be specified for the QuestionName, such as Q1_1, FF_name or GridQ1_r1_c1.