Skip to main content

Kinesis Support

All the topics, resources needed for Kinesis.

FocusVision Knowledge Base

Query For Sample

Query For Sample enables you to gather counts on a subset of panelists who meet certain criteria. The criteria are defined using the drag-and-drop query tool. After pulling back a subset of panelists, the subset is saved as a sample for sending invitations.

1:  Using Query Panel

1.1:  Section A - Actions

Create new query 
This button will take you to the query builder which will let you create and customize your new query.
Define new region 
Allows you to access the region editor page. Here you can create a new region to use with the query you're building (or for later use). Note that this icon will not appear unless you have mapped one or more of your datapoints to region keys (e.g. State/Province) in the Datapoint Manager.
Manage activity filters 
You will not see this icon if you don't have permission to create filters. Activity filters allow you to limit who the query selects based on their past activity. For example, to make sure you do not include someone who has already been invited to participate in three recent surveys, you can create a filter to select people who have been invited to more than two surveys in the past month, then create an "is not" condition to exclude people who match that filter condition.
Match panelist from file 
Launches the Match panelist from file feature.
Sample Manager 
You will be taken to the sample manager.
Create samples from selected 
Select one or more queries using the checkbox from the "Select" column. All selected queries will be saved as samples. This process happens in the background - you don't have to stay in the page and wait for it to finish.
Business rules 
If a box stating "Business rules are active" appears in the top bar, then it means that the panel manager has created a special query that will automatically be applied to any query you build. So if, for example, the business rules include a condition that all panelists pulled from the panel must not have been sent more that two invitations in the past month, then your sample will include only those panelists who meet this criteria, in addition to meeting the conditions you specify in your query.

1.2:  Section B - Folders

Recent queries  
Displays the last fifteen queries that were modified in the past week.
Filters 
Displays queries that are marked as filters. Filters that are created in other parts of the application, for example the panelist manager, will appear here.
Queries 
Displays all panel/project queries in the respective folders.
Shared queries 
Displays all shared queries that were not created in the current panel/project.
Invalid queries 
Displays all queries that have been marked as invalid. An invalid query is one that may make use of a non-existing sub-query, activity filter, or region. Once the invalid condition is corrected and saved, the query will not be marked as invalid. Sub-queries have been deprecated and all new conditions cannot be setup to use a sub-query. Any existing conditions using a sub-query will still execute as long as the query they point to exists and is valid. Existing sub-queries cannot be modified, only kept the same or removed.
Global queries 
Displays all queries that are currently shared.
Folders actions 
The following actions are available by right clicking the folders to bring up the folder modification menu. These actions only apply to the Queries folder and sub folders. Recent queries, Filters, Business rule, and Shared queries cannot be modified.
Create sub folder 
Creates a new folder within the folder.
Rename 
Allows renaming the folder.
Delete 
Deletes the folder.
Move selected 
Any queries that are selected in the list on the right side, will be moved into the selected folder.
Move 
Queries sub folders can be rearranged by dragging and dropping them to a different folder.

1.3:  Section C - Query List

Right clicking any row with a query will produce a context menu which contains the following options:

Preview 
Shows a breakdown of the selected query. Panelists who match the conditions are shown in green, and will be included if you save this query as a sample. Those shown in red do not match the conditions, and will not be included in a saved sample.
Copy 
This will copy a query with all of its groups and conditions.
Save as sample
This will run the selected query and produce a sample, which can then be used to invite panelists or to view stats on it.
Reserve as sample
Same as "Save as sample" except it will also reserve the sample for the next 24 hours, meaning all queries who are set to ignore panelists in reserved samples will do so.
Crosstabulation 
Use this button to run crosstabs on the selected query, you will be redirected to the crosstabs editor and your datapoints will be pre-selected for you (if possible).
Global
Clicking the checkbox in the Global column will toggle shared or not shared if the query originated from the current panel/project. Sharing queries allows queries to be used between the panel and other projects. Shared queries cannot be edited, deleted, or saved as a business rule unless they originated from this panel. Shared queries can always be copied to the current panel and then edited or saved as a business rule.
Delete 
This will delete a query. If a query is used as a subquery, the condition using it will be removed from the query. Clicking the trash bin in the list will also delete the query.

2:  Editing Your Query

Click the button, "Create new query" to begin.

2.1:  Section A - Actions

Guide me 

This button will open the help file for this page.

Query name 

Click the query name to edit it. Give your query a meaningful name to make it easier to find it again. Note: Every query must have a name.

Preview 

Use this button to quickly check query results.

Save query

Save the query as it currently is. It is not necessary to save a query in order for you to preview its result. Saving a query is also not necessary if you want to save its result as a sample (project mode only).

Save and clone query  

Save the current query, create an exact copy of it and make active for editing.

Save query, clone and save sample  

Save the current query, create an exact copy of it, make it active for editing and save it as sample.

Save as sample

This will save the results of the query as a sample and make it available in the sample manager.

Exit 

This will exit the query builder. Any unsaved changes are lost!

2.2:  Section B - Panelist fields / Datapoints / System fields / Groups / Filters

This section contains all available data sources separated into the three categories categories outlined below. Note: You will need to click and drag the fields from Section B to Section D. 
 

Panelist fields 

Contains a list of all panelist properties and meta data

Datapoints 

Contains a list of all datapoints

Filters 

Contains special fields that use more advanced logic. Available only when regions or activity filters are set up. 

2.3:  Section C - Query explained

This box contains a textual representation of the query that is being edited. 

2.4:  Section D - Query building area

This area is used to visualize the condition arrangement. You can drag items from the left sidebar into this field and place them in the specific order you desire. A query must have at least one condition in order for you to use it.

To edit a condition, click on the condition text itself and the Clause editor will display it.

The trash can icon allows you to delete a condition or an entire group and all its conditions.

The exclamation point icon allows you to negate a condition or an entire group.

To add a subgroup, click the 'plus' icon. Subgroups are used to clarify unambiguously which conditions should be evaluated first in the given query. Groups must always contain at least one condition.

To adjust a condtion or a group operand simply click it to change it from 'and' to 'or'. 

2.5:  Section E - Properties

Located in the top right section, the fields in this box allow you to adjust the query properties. 

Make available as a filter 

If you decide to make your query a filter, it becomes available in the panelist manager and data export.

Share query among all projects and panel 

Sharing queries allows queries to be used between the panel and other projects. Shared queries cannot be edited, deleted or saved as a business rule unless they originated from this panel.

Obey Panelist contact frequency settings 

When this is selected, the system will take the panelists contact frequency settings into consideration. Which means that a panelist will not be included in the query result, if he has already received enough invitations in his selected time span.

Include panelists even if reserved 

If this is selected, the system will include panelists from your query who are included in any reserved sample.

Additional de-duplication by data point

This shows a list of all available data points that can be used for additional de-duplication. The entries in the list are open end data points. Use this feature to group panelists by their answer for that data point. If duplicates are found, the system will randomly select one record to include in the query. Panelists who don't have an answer stored for the selected data point are excluded.

2.6:  Section F - Clause editor

This area is used to compose query conditions. After adding a condition, this field will allow you to edit its properties. Any changes made to the conditions are applied automatically - however the query you are editing or creating is not modified until you click the save button in the top toolbar.

For text questions used with either the "is any of" or "is non of" operators, the text box where you can paste the items list has been improved as it can now contain up to 100,000 rows; items lists must be comma separated lists. The "is any of" or "is non of" operators are case insensitive, commas are always treated as line breaks, and data must match exactly (ex: "TEST1" will not return "TEST12").

Queries containing subqueries will still run, but they can no longer be added or edited. Use subgroups instead.

  • Was this article helpful?