Welcome to the page, dedicated to my former job in Ulter Systems
This page is under construction now !

This page is dedicated to QSL - Questionnaire Specification Language for market researchers, worked out by Pulse Train Technology Ltd (PTT) for their  Bellview interviewing system and other parts of Research machine.

QSL, BELLVIEW, RESEARCH MACHINE are trademarks of PTT , Copyright © 1987-1997.

Look at the demo0.qsl file which contains the 2nd phase of the DEMOnstrative survey script.   IS IT CLEAR what it can do ?
  1. DEMO script dialogue executing.
  2. Using QSL scripts in Bellview.
  3. QSL scripts conversion into C++ | Java | JavaScript.
  4. REDO of questions and GOBACK mode.
  5. Further discussions and copyright.
    1. You can run my old <Html+JavaScript> applet DEMO.HTM which executes the script dialogue.   BEFORE the run  memorize the next rules:
    • for alphanumeric input in the bottom fields you should [A] FOCUS them with the mouse [B] TYPE anything new ( 0, 1, <number>, <text> ) and [C] press TAB,
    • click on the right bottom buttons is equal to "input 0" which usually means acknowledgement of the previous changes and leap to the next question; DON'T click instead of pressing TAB (it will be double event for JavaScript),
    • if you have enough patience to reach and press SUBMIT button, you'll mail me filled form which is visible under the SUBMIT button.
    You can also run my Java applet with BVDEMO.HTM.

    REMEMBER, that answers should be typed in the applet BOTTOM textarea field and the FOCUS should be given to the textarea in the beginning with the mouse.

    2. QSL's scripts are translated into Research Machine's ECD codes and files, which are executed in BELLVIEW interviewing system. ECD codes contain numbers of lines of the TXG file, which are used for static or DYNAMIC TEXT SUBSTITUTION.

    Look at the demo1.qte file which is composed from the fragments of the source QSL and secondary TXG and ECD files. It contains lines of demo0.qsl with correspondent <TXG> lines and <ECD> codes which are interpreted on VMS, UNIX or Windows BELLVIEW.


    The small fragment of the   demo1.qte   =   Qsl + Txg + Ecd   file follows
    NIGHT:M,qt\        <%name>, what nights of the week would you and 
                    <%friend> be available to attend <%show>. ( Or <%second> 
                    or <%third>, if <%show> is sold out).\,
            post\   Please indicate all acceptable evening\,
            alist\  Monday, Tuesday, Wednesday, Thursday, Friday, Saturday\;
    
    < TXG> 29 D%9., what nights of the week would you and %14. be available to 
               attend %11.. (Or %12. or %13., if %11. is sold out). #FR ... #DE ...
           30  Please indicate all acceptable evenings 
               #FR Veuillez indiquer toutles soirs libres 
               #DE Bitte an allen erwuenschten Abende zeigen 
           31  Monday #FR Lundi #DE Montag 
    ...
           36  Saturday #FR Samedi #DE Samstag 
    < ECD>   2  16; 47  15; 14   0  29  30 123   6  15  13   0
            16   8;247  31  36; 46
    
    compute nights count(night) ;
    < ECD>  19; 87 123   6; 99   6; 98   6; 53   1
    
    if \If refusal in <>, read out text below\ nights == 0;
    
    < TXG> 37  If refusal in 13, read out text below 
    < ECD>  19; 34   1; 35   0; 41; 45  22   0
    
            display\Sorry, I need to know that.  Please indicate at
                    least one night of the week.\;
    < TXG> 38  Sorry, I need to know that. Please indicate at least one night of 
               the week. #FR Je suis desole... #DE Verzeitung, das muss ich aber...
    < ECD>   2  23;  3  38   0; 46
    
    GOTO night;
    < ECD>   1  16;  1  21
    
    elseif \If more than one night, ask:\ nights>>1;
    
    < TXG> 39  If more than one night, ask: 
    < ECD>   2  22; 19; 34   1; 35   1; 39; 45  24   0
    
            best_night:S include(night),
            qt\     Because you indicated < ( nights ) > nights, 
                            I need to know the preferred night.\,
                    AS night;
    ...
    Top of the page   Thank you very much if you continue reading !   Return to HOME page


    3. Look at the demo2.qsl file that is equal to the demo0.qsl file.
    The demo2.qsl file can be converted into the demo3.q1c file which contains analogies of TXG and ECD : TEXTUAL part (lines for text substitutions) and ACTION part (the sequence of questions, control and calculations).

    Look at the demo4.q2c file which ACTION part is rather simple (without REDO/Backward mode support which is described in the next chapter). It's text lines can be padded with overriding virtual functions which are named in the demo.cpp file as   Get_Pre , Get_Head , Get_List , Get_Post and Forward   (they were defined in the ancestor FoQSL class).

    Look at the demo5.cpp file which contains two parts (TEXTUAL and ACTION) from the previous version of the demo.cpp file (that's demo11.cpp). These two part could be generated from the QSL program (other parts can be linked or included to generated program in C++ | Java | JavaScript). You can see in the TEXTUAL part of the demo5.cpp file the quoted strings from the demo4.q2c file. The ACTION (3d) part of the demo5.cpp contains the next question selections, which are simple in this DEMO survey.

    You can load, save, compile and run the demo.cpp file.

    This file can be compiled in Windows mode - without "//" before the line 7:
      #define MY_WYNDOWS
    or in character input/output mode (with commented // before the line 7).
    One can decomment "MY_WIN_CE" or "_UNICODE" submodes of the MY_WINDOWS mode.
    Character mode includes the "SCANF" specification (for using scanf instead of getchar : for "scanf" one should answer "0" as an empty answer), and the "NDP" specification (for NDP C++ in SCO UNIX).
    If you compiled it and make a program it will simulate the Bellview DEMO run on the terminals 80x24. The last line you'll see on the screen is the 2nd phase part of DR - Data Record. DR consists of the question sequence buffers. DR is stored after interview in Bellview database.


    The JAVA application or applet may be produced by padding with similar overriding methods which used "StringBuffer" methods instead of the "strcat" function. One can SEE the JAVA couple of "application and applet" in the BVdemo.java file. You can also run my Java applet with bvdemo.htm.

    Remember, that answers should be typed in the Applet bottom textarea field and the Focus should be given to the textarea in the beginning with the mouse.

    The BVdemo.java can be loaded, saved, JAVACompiled and run with JAVA program as an application. It works with System.out... and System.in... character mode methods in the application mode.
    One can also start it with "appletviewer" or browser, because it contains
    init() , start() , run() , stop() , paint(...) , action(...)
    applet methods in addition to static main() method of an application.


    The JavaScript doesn't have defined classes or overriding. But it allows constructors of multy-properties' objects. JavaScript applet can be realized with encapsulation of the TEXTUAL functions into the screen properties constructor for the question ( this.Pre , this.Head , this.Post , this.1... for Get_List(1)... ). These constructors should be called before JavaScript analogue of QSLput (which used properties instead of overriding functions). They should be called in the Forward_<question_name> functions, which were invoked by onClick/onChange triggers.

    Top of the page   Thank you twice if you continue reading !!   Return to HOME page


    4. One of the most cool features of RESEARCH MACHINE is REDO of questions and GOBACK mode. One can redo the question just finished or any previous, specified by name. One can also goback and REDO part of questions, keeping previous answers or modifying them. These features can be supported by the second chain of question classes (the first is used for text substitution).

    These classes are named <QUESTION>_Tape because the object of them can include
    • Left part (previous states of this question) which is left stack (or left part of question's tape),
    • Middle object = current state buffer,
    • Right part (earned input) which should be stored in GOBACK mode; it is a right stack (or right part of question's tape).
      Tape for every question is looked like

    ___________________________________________________
    ... | - 2nd | - 1st |current| + 1st | + 2nd | ...
    ... | state | state | state | state | state | ...

    The tape classes of DISPLAY operators can
    • be absent (it's an usual case),
    • contain the pointer of the PREVIOUS question (if there are extra GOTO on this display operator),
    • contain the values of the variables, which are COMPUTEd in it's ACTION part (before the next question) by operators without the inverse.
    The example of the operator with inverse is   i = i + 1 ; the inverse for it is   i = i - 1. The operator   i = 1 is an operator without inverse (if the previous value of "i" can't be calculated by the previous formula now i.e. is wasn't i = 0 or anything simple early in a chain of operators). If we can't reset computed variable by the simple formula we can store it's value for possible restore in GOBACK.


    The tape classes of the QUESTION operator can't be absent. They contain "char ... [ <VARIABLE_LENGTH> ];" for the previous value of the variable. Tape classes encapsulate the next data
    • one or two references (to the previous/next cell of the tape),
    • question variable value before the input
    • pointer to the PREVIOUS question (if there are extra GOTO here),
    • values of the variables, which are COMPUTEd in it's ACTION part.
    Look at the demo3.q1c ACTION part. There are the extra chain of BACKWARD actions and two extra operators : RIGHT and LEFT. RIGHT and LEFT use the "<QUESTION>_Temp" objects which are "middle objects = current state buffers".
    The RIGHT operator pseudocode is
    1. store current values into "<QUESTION>_Temp" (or leave them there),
    2. put "<QUESTION>_Temp" to the LEFT stack ( = move RIGHT on tape),
    3. check IF the RIGHT part of tape exist (we are after GOBACK),
    4. if FALSE then CREATE NEW "<QUESTION>_Temp" else
    5.   TRY the RIGHT question values as the INPUT before confirmation,
    6.   USE RIGHT object as a new "<QUESTION>_Temp" (= RIGHT move); The LEFT operator pseudocode is
      1. store current question values into "<QUESTION>_Temp" (or leave them there),
      2. put "<QUESTION>_Temp" to the RIGHT stack ( = move LEFT on tape),
      3. RESTORE the values from the LEFT tape object,
      4. USE LEFT tape object as a new "<QUESTION>_Temp" (= LEFT move); There are no check of the LEFT stack existing because it must exist. And if one used tape classes instead of DR and part of temporaries, there were only right/left move with the option "if RIGHT is absent, copy the current to the right

        Look at the demo3.q1c ACTION part. There are no LEFT/RIGHT for DISPLAY operators. There are no need to store variables (temp is calculated from the input value) and both multy-entered operators are QUESTIONs. One can see "GOTO <POPPED>" in the NIGHT and WHY questions. It means that Night_Temp and Why_Temp should contain the previous operator pointer for the right GOBACK. Other questions contain the question value only.

        Top of the page   Thank you again if you continue reading !!!   Return to HOME page


        5. Copyright © 1997. Yuriy V. Stupak , Ulter Systems Ltd , Pulse Train Technology ; All this materials intended for non-exclusive use; REFERENCE is needed.

        If you are interested in
        "academical discussion" of the technology of dialogue scripts implementation for WEB, I'll be very thankful for your mail to my personal stoupak@home.com mailbox.

        REMEMBER, the compiler for QSL with executive part (or their WEB client analogies) are the less part of all survey support software - from the sample preparation and interview supervising to statistic analysis and results preparation.
        If you need  efficient  tool , ask  proficient  developers.

        If you are interested in commercial QSL or Visual QSL based applications for WEB, send mail to our director Leonid Sokolovsky leo@ultersys.ru

        Top of the page             Visit number       Return to HOME page
        1234