Query-based selection is used when you want to define a portfolio that includes all of the items that comply with the query's definition.
You can use query-based selection to define the portfolio and then convert the portfolio to manual selection for editing and updating.
To use a query to specify which items to include in the portfolio:
- On the Items tab of the Portfolio Wizard, select Query.
- In the Query Scope area, define the scope of the query.
To include all the portfolios in the query, select All Portfolios.
To limit the query to specific portfolios, select Limit to Selected Portfolios and then click Select. In the Portfolios dialog box, choose the portfolios that you want to query and then select OK. To select more than one portfolio, hold down the Shift or Ctrl key while selecting.
After you select portfolios, select Edit to add or remove portfolios from the query. To add portfolios to the query, select Add. To remove a portfolio from the query, select it and then select Remove.
Click OK to save your selections and return to the Items (or Portfolios) step.
- In the Query Definition area, define the conditions that the items or portfolios must satisfy.
For each condition, specify the following information:
- Category: The category of the condition. Each category type has a predefined set of operators and values that populate the drop-down lists when the category is selected. If the category includes indicator values, additional operators are available.
- Operator: The operator for the condition.
- Value: The value or values for the condition. You can select multiple values with the Ctrl or Shift keys. If the value is a date, you can select it from a calendar.
- And /Or: The relationship between the query and the subsequent query.
You may group conditions and set logical relations between the groups by adding separator lines. To turn a blank line into a separator line, choose an And/Or value for the line and then select another field in the next line.
Select the up or down arrows, or select Remove to move or delete a selected criterion.
- Click Permissions to view or change the query permissions (to read more about query permissions see About Query Based Portfolio Security. The Query Permissions dialog box appears.
- In the User list, select a user. You can select any user from the list as long as you can provide a password for the selected user.
- In the Password field, enter the selected user's password and click OK to save the query permissions.
- In the Periodic update list, specify how often you want the query to be updated. You can select None if you don't want the query to be updated, select Standard, Frequent, or Customized to have the query automatically updated. The administrator can control the frequency with which query based portfolios are updated. For more information on scheduling tasks, refer to Scheduling Tasks .
- Click Run to run the query. The query results appear in the Query Results area. Query results include all the data that matches the criteria entered in the Query Definition area.
The date and time of the last instance the present query was run, and the name of the person who ran the query, appear at the bottom of the Items (of Portfolios) step.
- To convert items selected by the query to manually selectable items, click Convert.
Notes:
- Converting the selection method for the current portfolio is irreversible. The next time you wish to edit that portfolio, the Manual Selection dialog box will appear.
- Query based portfolios can also be refreshed and updated by clicking Run in the Query Based Selection dialog box. Always click Finish to save the results.
- Select Next to proceed to the next tab of the wizard, or select Finish to save the portfolio and exit the wizard.