**QUERY MODULE TEST CASES**

**TEST CASE 3-Simple Query using OR & AND option**

**Narrative:** The TTB Administrator is preparing a quarterly report &
would like to search for all reported problems with subject of failed
search in the last 90 days at Presbyterian, HUP or Pennsylvania Hospital

+------+-------------------+-------+---------+----------+-----------+---+
| **M  |                   |       | **Test  |          |           |   |
| odul |                   |       | Case    |          |           |   |
| e:** |                   |       | Name:** |          |           |   |
| Q    |                   |       | TEST    |          |           |   |
| uery |                   |       | CASE    |          |           |   |
|      |                   |       | 3       |          |           |   |
|      |                   |       | -Simple |          |           |   |
|      |                   |       | Query   |          |           |   |
|      |                   |       | using   |          |           |   |
|      |                   |       | OR      |          |           |   |
|      |                   |       | option  |          |           |   |
+======+===================+=======+=========+==========+===========+===+
| **   |                   |       | **Pas   |          |           |   |
| Test |                   |       | s/Fail: |          |           |   |
| Dat  |                   |       | Pass**  |          |           |   |
| e:** |                   |       |         |          |           |   |
| 1/1  |                   |       |         |          |           |   |
| 1/06 |                   |       |         |          |           |   |
+------+-------------------+-------+---------+----------+-----------+---+
| **Te |                   |       |         |          |           |   |
| ster |                   |       |         |          |           |   |
| Nam  |                   |       |         |          |           |   |
| e:** |                   |       |         |          |           |   |
| Tara |                   |       |         |          |           |   |
| McSh |                   |       |         |          |           |   |
| erry |                   |       |         |          |           |   |
+------+-------------------+-------+---------+----------+-----------+---+
| **P  | To test if a User |       |         |          |           |   |
| urpo | **(TTB            |       |         |          |           |   |
| se** | Administrator)**  |       |         |          |           |   |
|      | may perform a     |       |         |          |           |   |
|      | search using the  |       |         |          |           |   |
|      | OR option.        |       |         |          |           |   |
+------+-------------------+-------+---------+----------+-----------+---+
| **Pr | **Assumption:**   |       |         |          |           |   |
| ereq |                   |       |         |          |           |   |
| uisi | \*User has        |       |         |          |           |   |
| te** | privileges to     |       |         |          |           |   |
|      | query information |       |         |          |           |   |
|      |                   |       |         |          |           |   |
|      | \*User login      |       |         |          |           |   |
|      | successful        |       |         |          |           |   |
|      |                   |       |         |          |           |   |
|      | \*All test data   |       |         |          |           |   |
|      | information has   |       |         |          |           |   |
|      | been previously   |       |         |          |           |   |
|      | entered.          |       |         |          |           |   |
+------+-------------------+-------+---------+----------+-----------+---+
| **   | **Affiliation:**  |       |         |          |           |   |
| Test | Presbyterian, HUP |       |         |          |           |   |
| Da   | & Pennsylvania    |       |         |          |           |   |
| ta** |                   |       |         |          |           |   |
|      | **Subject:**      |       |         |          |           |   |
|      | failed search     |       |         |          |           |   |
+------+-------------------+-------+---------+----------+-----------+---+
|      |                   | **Exp |         | **Actual |           |   |
|      |                   | ected |         | Re       |           |   |
|      |                   | Resu  |         | sults/Co |           |   |
|      |                   | lts** |         | mments** |           |   |
+------+-------------------+-------+---------+----------+-----------+---+
|      |                   |       |         | Linux    | Windows   |   |
|      |                   |       |         | Server   | Server    |   |
+------+-------------------+-------+---------+----------+-----------+---+
| *    | 1\. User selects  | 1\.   |         | \*       | \         |   |
| *Ste | the Search        | S     |         | Expected | *Expected |   |
| ps** | dashboard view.   | earch |         | results  | results   |   |
|      |                   | o     |         | were     | were      |   |
|      | 2\. User selects  | ption |         | returned | returned  |   |
|      | the Simple search | is    |         |          |           |   |
|      | option.           | disp  |         |          |           |   |
|      |                   | layed |         |          |           |   |
|      | 3\. The User      | on    |         |          |           |   |
|      | selects "reported | the   |         |          |           |   |
|      | problem" from the | HOME  |         |          |           |   |
|      | 1^st^ drop down   | dashb |         |          |           |   |
|      | box.              | oard. |         |          |           |   |
|      |                   | S     |         |          |           |   |
|      | 4\. The User      | earch |         |          |           |   |
|      | selects           | op    |         |          |           |   |
|      | "affiliation"     | tions |         |          |           |   |
|      | from the 2^nd^    | are   |         |          |           |   |
|      | drop down box.    | pres  |         |          |           |   |
|      |                   | ented |         |          |           |   |
|      | 5\. The User      | on    |         |          |           |   |
|      | selects "equals"  | the   |         |          |           |   |
|      | from the 3^rd^    | sc    |         |          |           |   |
|      | drop down box.    | reen. |         |          |           |   |
|      |                   |       |         |          |           |   |
|      | 6\. The User      | 2\.   |         |          |           |   |
|      | enters            | User  |         |          |           |   |
|      | "Presbyterian" in | is    |         |          |           |   |
|      | the data field.   | able  |         |          |           |   |
|      |                   | to    |         |          |           |   |
|      | 7\. The User      | s     |         |          |           |   |
|      | selects the       | elect |         |          |           |   |
|      | **OR** button.    | this  |         |          |           |   |
|      |                   | o     |         |          |           |   |
|      | 8\. The User      | ption |         |          |           |   |
|      | selects "reported | suc   |         |          |           |   |
|      | problem" from the | cessf |         |          |           |   |
|      | 1^st^ drop down   | ully. |         |          |           |   |
|      | box in the 2^nd^  | S     |         |          |           |   |
|      | row.              | imple |         |          |           |   |
|      |                   | s     |         |          |           |   |
|      | 9\. The User      | earch |         |          |           |   |
|      | selects           | data  |         |          |           |   |
|      | "affiliation"     | f     |         |          |           |   |
|      | from the 2^nd^    | ields |         |          |           |   |
|      | drop down box in  | are   |         |          |           |   |
|      | the 2^nd^ row.    | displ |         |          |           |   |
|      |                   | ayed. |         |          |           |   |
|      | 10\. The User     |       |         |          |           |   |
|      | selects "equals"  | 3\.   |         |          |           |   |
|      | from the 3^rd^    | All   |         |          |           |   |
|      | drop down box in  | cor   |         |          |           |   |
|      | the 2^nd^ row.    | respo |         |          |           |   |
|      |                   | nding |         |          |           |   |
|      | 11\. The User     | op    |         |          |           |   |
|      | enters "HUP" in   | tions |         |          |           |   |
|      | the data entry    | are   |         |          |           |   |
|      | field.            | disp  |         |          |           |   |
|      |                   | layed |         |          |           |   |
|      | 12\. The User     | in    |         |          |           |   |
|      | selects the       | the   |         |          |           |   |
|      | **OR** button.    | 2^nd^ |         |          |           |   |
|      |                   | drop  |         |          |           |   |
|      | 13\. The User     | down  |         |          |           |   |
|      | selects "reported | box.  |         |          |           |   |
|      | problem" from     |       |         |          |           |   |
|      | 1^st^ drop down   | 4-5.  |         |          |           |   |
|      | box in the 3^rd^  | User  |         |          |           |   |
|      | row.              | s     |         |          |           |   |
|      |                   | hould |         |          |           |   |
|      | 14\. The User     | be    |         |          |           |   |
|      | selects           | able  |         |          |           |   |
|      | "affiliation"     | to    |         |          |           |   |
|      | from the 2^nd^    | s     |         |          |           |   |
|      | drop down box in  | elect |         |          |           |   |
|      | the 3^rd^ row.    | this  |         |          |           |   |
|      |                   | o     |         |          |           |   |
|      | 15\. The User     | ption |         |          |           |   |
|      | selects "equals"  |       |         |          |           |   |
|      | from the 3^rd^    | 6\.   |         |          |           |   |
|      | drop down box in  | \# of |         |          |           |   |
|      | the 3^rd^ row.    | Chara |         |          |           |   |
|      |                   | cters |         |          |           |   |
|      | 16\. The User     | s     |         |          |           |   |
|      | enters            | hould |         |          |           |   |
|      | "Pennsylvania" in | be    |         |          |           |   |
|      | the data entry    | all   |         |          |           |   |
|      | field.            | owed. |         |          |           |   |
|      |                   |       |         |          |           |   |
|      | 17\. The User     | 7\.   |         |          |           |   |
|      | selects the       | 2^nd^ |         |          |           |   |
|      | **AND** button.   | row   |         |          |           |   |
|      |                   | of    |         |          |           |   |
|      | 18\. The User     | drop  |         |          |           |   |
|      | selects "reported | down  |         |          |           |   |
|      | problem" from the | boxes |         |          |           |   |
|      | 1^st^ drop down   | &     |         |          |           |   |
|      | box in the 4^th^  | data  |         |          |           |   |
|      | row.              | field |         |          |           |   |
|      |                   | s     |         |          |           |   |
|      | 19\. The User     | hould |         |          |           |   |
|      | selects "Subject" | be    |         |          |           |   |
|      | from the 2^nd^    | displ |         |          |           |   |
|      | drop down box in  | ayed. |         |          |           |   |
|      | the 4^th^ row.    |       |         |          |           |   |
|      |                   | 8\.   |         |          |           |   |
|      | 20\. The User     | Same  |         |          |           |   |
|      | selects "equals"  | as    |         |          |           |   |
|      | from the 3^rd^    | #3.   |         |          |           |   |
|      | drop down box in  |       |         |          |           |   |
|      | 4^th^ row.        | 9-10. |         |          |           |   |
|      |                   | Same  |         |          |           |   |
|      | 21\. The User     | as    |         |          |           |   |
|      | enters "failed    | #4-5. |         |          |           |   |
|      | search" in the    |       |         |          |           |   |
|      | data entry field. | 11\.  |         |          |           |   |
|      |                   | Same  |         |          |           |   |
|      | 22\. The User     | as    |         |          |           |   |
|      | selects the       | #6.   |         |          |           |   |
|      | **Search**        |       |         |          |           |   |
|      | button.           | 12\.  |         |          |           |   |
|      |                   | 3^rd^ |         |          |           |   |
|      |                   | row   |         |          |           |   |
|      |                   | of    |         |          |           |   |
|      |                   | drop  |         |          |           |   |
|      |                   | down  |         |          |           |   |
|      |                   | boxes |         |          |           |   |
|      |                   | &     |         |          |           |   |
|      |                   | data  |         |          |           |   |
|      |                   | field |         |          |           |   |
|      |                   | s     |         |          |           |   |
|      |                   | hould |         |          |           |   |
|      |                   | be    |         |          |           |   |
|      |                   | displ |         |          |           |   |
|      |                   | ayed. |         |          |           |   |
|      |                   |       |         |          |           |   |
|      |                   | 13\.  |         |          |           |   |
|      |                   | Same  |         |          |           |   |
|      |                   | as    |         |          |           |   |
|      |                   | #3.   |         |          |           |   |
|      |                   |       |         |          |           |   |
|      |                   | 1     |         |          |           |   |
|      |                   | 4-15. |         |          |           |   |
|      |                   | Same  |         |          |           |   |
|      |                   | as    |         |          |           |   |
|      |                   | #4-5. |         |          |           |   |
|      |                   |       |         |          |           |   |
|      |                   | 16\.  |         |          |           |   |
|      |                   | Same  |         |          |           |   |
|      |                   | as    |         |          |           |   |
|      |                   | #6.   |         |          |           |   |
|      |                   |       |         |          |           |   |
|      |                   | 17\.  |         |          |           |   |
|      |                   | 4^th^ |         |          |           |   |
|      |                   | row   |         |          |           |   |
|      |                   | of    |         |          |           |   |
|      |                   | drop  |         |          |           |   |
|      |                   | down  |         |          |           |   |
|      |                   | boxes |         |          |           |   |
|      |                   | &     |         |          |           |   |
|      |                   | data  |         |          |           |   |
|      |                   | field |         |          |           |   |
|      |                   | s     |         |          |           |   |
|      |                   | hould |         |          |           |   |
|      |                   | be    |         |          |           |   |
|      |                   | displ |         |          |           |   |
|      |                   | ayed. |         |          |           |   |
|      |                   |       |         |          |           |   |
|      |                   | 18\.  |         |          |           |   |
|      |                   | Same  |         |          |           |   |
|      |                   | as    |         |          |           |   |
|      |                   | #7.   |         |          |           |   |
|      |                   |       |         |          |           |   |
|      |                   | 1     |         |          |           |   |
|      |                   | 9-20. |         |          |           |   |
|      |                   | Same  |         |          |           |   |
|      |                   | as    |         |          |           |   |
|      |                   | #4-5. |         |          |           |   |
|      |                   |       |         |          |           |   |
|      |                   | 21\.  |         |          |           |   |
|      |                   | Same  |         |          |           |   |
|      |                   | as    |         |          |           |   |
|      |                   | #6.   |         |          |           |   |
|      |                   |       |         |          |           |   |
|      |                   | 22\.  |         |          |           |   |
|      |                   | The   |         |          |           |   |
|      |                   | S     |         |          |           |   |
|      |                   | ystem |         |          |           |   |
|      |                   | con   |         |          |           |   |
|      |                   | ducts |         |          |           |   |
|      |                   | a     |         |          |           |   |
|      |                   | s     |         |          |           |   |
|      |                   | earch |         |          |           |   |
|      |                   | for   |         |          |           |   |
|      |                   | all   |         |          |           |   |
|      |                   | rep   |         |          |           |   |
|      |                   | orted |         |          |           |   |
|      |                   | f     |         |          |           |   |
|      |                   | ailed |         |          |           |   |
|      |                   | sea   |         |          |           |   |
|      |                   | rches |         |          |           |   |
|      |                   | at    |         |          |           |   |
|      |                   | Pre   |         |          |           |   |
|      |                   | sbyte |         |          |           |   |
|      |                   | rian, |         |          |           |   |
|      |                   | HUP   |         |          |           |   |
|      |                   | or    |         |          |           |   |
|      |                   | Pen   |         |          |           |   |
|      |                   | nsylv |         |          |           |   |
|      |                   | ania. |         |          |           |   |
+------+-------------------+-------+---------+----------+-----------+---+
| **N  | \*Tester needed   |       |         |          |           |   |
| otes | to insert problem |       |         |          |           |   |
| and  | reports prior to  |       |         |          |           |   |
| Que  | this test case    |       |         |          |           |   |
| stio |                   |       |         |          |           |   |
| ns** |                   |       |         |          |           |   |
+------+-------------------+-------+---------+----------+-----------+---+