Quota Statements

Quotas are incrementing counters that are kept across interviews (on a stand-alone PC), and across interviewers (in a shared files environment). These are usually used to determine whether to continue an interview or not based on a set of questions or information collected at the beginning of the interview. The quotas can also be used just to keep track of counts during the interviewing period. The quota values can be seen or modified using the QUOTAMOD and SURVSUPR programs or they can be written to the data or phone file to be used later in reports.

QUOTA statements cause a counter in the QUO file to be updated. The QUOTA function will tell you the value of the named quota at the start of the interview. The current quota value can be obtained using the QUOTA NOW or QUOTN functions (See USING FUNCTIONS IN CONDITION STATEMENTS). The READ_NAMED_QUOTAS compiler command will get you the current value of all named quotas. The MODQUOTA and MODQUOTN functions can be used to determine how often a particular quota has been updated in an interview.

The syntax for this quota statement is:

!QUOTA,subtype,<quota name or location of name to increment>,amount to increment,<NOW>

Valid Subtypes

  • Regular
  • Regular_Numbered


This subtype is the default and updates standard named quotas.  The quota to increment is a quota name, question label, or data location that stores a quota name to be updated. If it is a question label or data location, it must have parenthesis () around it.

Quota names can be up to 30 characters long, using alphanumeric characters, periods (.), or underscores (_). Quota names must begin with an alpha character, except they cannot begin with QQ to avoid confusion with question number references. They also cannot end with a period followed by numbers only; this is to avoid confusion with data location references. If using TRIPLEQUOTAS mode (described later), quota names are limited to 28 characters since .R and .T will be added to the name to designate the resettable and target quotas.


This subtype is used for numbered quotas. The quota to increment refers to the quota number to increment. It can be a specific number, question label, or data location which contains the number of the quota to increment. More information on numbered quotas is discussed later in this section. You can have both subtypes regular and regular_numbered quota statements in the same interview.

Incrementing Quotas

The quota increment is usually 1 if counting interviews, but it can be any number (including a negative number to decrement), question label, or data location containing the number to increment the quota with. Zero increment of quotas is allowed. The increment can also be specified as a particular number to change to by preceding it with an equal sign (=).



When specified in this manner, the comma between the quota name and the value is optional (i.e., OREGON=10).

The NOW option would cause the quota to be incremented immediately. This may be necessary for long interviews (so that new interviews will not start in the interim), or if you wish to update a quota prior to an interview being suspended. The default is that the quota is incremented when the interview is completed and a record is written, regardless of when the quota statement was executed. This is to guard against quotas being updated for interviews that may end up being terminated. Therefore, use the NOW option with caution.

If the interview is aborted without writing a case, standard quota updates are dropped, with only QUOTA NOW updates being done.



This example is using subtype regular (the default, since none was specified). The quota named NEW_YORK will be incremented by 1 at the end of the interview if the data is saved.

You can also reference a data location where the quota label is stored in the quota statement. In this way, you can write one statement that requests an update of the value of the quota found in a certain location instead of one statement per each possible quota updated. This is similar to the way numbered quotas work.

The syntax to do this is:

!QUOTA,REGULAR,[<label or location>],+1<,now>

“Label or location” is the place where the quota name is stored. This works particularly well when your quota name is based off the market name or it comes from the sample file.



{ QNAME: .5

Body of questionnaire


In this example, the quota name is derived from the market name, and it is updated by pointing to a !SPECIAL,SAVE_TEXT_LINE_TO_DATA question which loads the quota name based on the market field. If you put a reference in brackets [], it knows to check the data location and use that label. If you have a label only, it assumes that is the name of the quota.

NOTE1: Use Markets and the PHONE,ASSIGN_MARKET_WEIGHT statement to keep sample that is over quota from being picked up by the interviewer (See MARKETS for more information).

NOTE2: Quota statements are checked during the compile. Previously you could have a problem if you had a typo on a quota check statement or a !QUOTA name; if they didn’t match, both names would go in the quota file and the checking would not work correctly. Now, if you have a quota reference that does not have a corresponding !QUOTA or !SET_QUOTA statement, an error is generated.

To OVERRIDE the checking, add “ALLOW_UNSET_QUOTAS” in the questionnaire header.