ArcGIS Desktop

  • ArcGIS Pro
  • ArcMap

  • My Profile
  • Help
  • Sign Out
ArcGIS Desktop

ArcGIS Online

The mapping platform for your organization

ArcGIS Desktop

A complete professional GIS

ArcGIS Enterprise

GIS in your enterprise

ArcGIS Developers

Tools to build location-aware apps

ArcGIS Solutions

Free template maps and apps for your industry

ArcGIS Marketplace

Get apps and data for your organization

  • Documentation
  • Support
Esri
  • Sign In
user
  • My Profile
  • Sign Out

ArcMap

  • Home
  • Get Started
  • Map
  • Analyze
  • Manage Data
  • Tools
  • Extensions

Configuring public job queries

Available with Standard or Advanced license.

Available with Workflow Manager license.

  • Adding query folders
  • Adding queries
  • Viewing in SQL
  • Sharing queries

Several job query containers and queries are present by default in the ArcGIS Workflow Manager for Desktop. These include General Queries (All Jobs query and Unassigned Jobs query), Group Queries (Jobs assigned to my groups and Jobs with steps assigned to my groups), and Personal Queries (Jobs assigned to me and Jobs with steps assigned to me). Job queries in these folders are managed in the Workflow Manager Administrator and are available to all users of the system. Users can set any of these as a default query, and that query will execute by default every time the Workflow Manager application opens.

Set default query

Note:

Jobs returned by these queries are affected by job filters applied to groups the user belongs to. Default query currently only work for Windows users and does not support portal users.

Adding query folders

Use the tools available to add query containers that will be used to organize your queries in the client application.

  1. In the Administrator, browse to the Job Queries folder.
  2. Choose the query folder where you want the new folder to reside.

    The Public Queries folder that you see in the view is the highest level folder.

  3. Right-click and choose Add Query Container.
  4. Provide a name for the folder.

    This name will be presented to the Workflow Manager System users in the client application.

  5. Click OK to create the new folder.

    This folder is now available to contain other folders or queries.

Adding queries

Use the tools available to configure queries that will be used to filter your jobs in the application.

  1. In the Administrator, browse to the Job Queries folder.
  2. Choose the query folder where you want the new query to reside.

    The Public Queries folder that you see in the view is the highest level folder.

  3. Right-click and choose Add Query.

    The Define Job Query dialog box appears.

  4. Provide a name for the query on the General tab.
  5. Click the Fields tab.

    This is where you'll choose the job information to be presented to the user in the List View when the query is executed. Workflow Manager automatically manages the inter-table relationships within the system. By expanding nodes off of the fields in the job table, you can choose to show more descriptive information in the query result.

  6. Add fields to the list by double-clicking them or dragging them to the column on the right.

    Query fields
    Add fields to the list. These represent the information that will be presented to the user when the query is executed.

  7. Click the Aliases tab.

    On this tab, you can change the name used to represent each field. You can also reorder the fields. The top field will be the first field on the left, and the bottom field will be the last field on the right.

  8. Change the aliases and order as necessary.

    Aliases tab
    Change the presentation name and order of fields in the query on the Aliases tab.

  9. Click the Filtering tab.

    Define which jobs should be returned by this query based on the filter criteria.

  10. Define the conditions by selecting the field you want to use to query, the operator, and the value the job must meet.

    You can add as many conditions as you want.

  11. Create the filtering statement in the lower section by linking each condition together with ANDs, ORs, and parentheses.

    Filtering tab
    Build the where clause for your query on the Filtering tab.

  12. Click OK to save your changes and close the dialog box.

    The query will appear in the client application the next time you open it.

  13. Note:

    Click Preview SQL to see the SQL statement generated for your queries.

Viewing in SQL

The SQL view is for advanced users who want to construct queries with the traditional SQL statements. These tools allow you to define more complex queries for filtering jobs in the application.

  1. In the Administrator, browse to the Job Queries folder.
  2. Choose the query folder where you want the new query to reside.

    The Public Queries folder that you see in the view is the highest level folder.

  3. Right-click and choose Add Query.

    The Define Job Query dialog box appears.

  4. Provide a name for the query on the General tab.
  5. Click the SQL Query tab.
    SQL view
  6. Click a table from the Tables list to populate the Fields list with all the fields in the selected table.
  7. Choose a field and click Get All to populate the Unique Values list with all values in the selected field.
  8. Select the command component (Select, Name As, and so on) with your cursor, and double-click the table or field you want to add.
  9. Specify the Where clause to define which jobs should be returned by this query.
  10. Click Verify to confirm that the query is valid and click OK to add the query to your job query tree.

Sharing queries

It's possible to use an existing query as the base for another using the Export option on the Define Job Query dialog box.

  1. Right-click the query and choose Edit Item on the query you want to export.
  2. Click Export.
  3. Provide a location and file name for the exported query.
  4. Click Save.

A .jtq file is created. This query file can be imported to use as a base for a new query or shared between users and Workflow Manager systems.

ArcGIS Desktop

  • Home
  • Documentation
  • Support

ArcGIS

  • ArcGIS Online
  • ArcGIS Desktop
  • ArcGIS Enterprise
  • ArcGIS
  • ArcGIS Developer
  • ArcGIS Solutions
  • ArcGIS Marketplace

About Esri

  • About Us
  • Careers
  • Esri Blog
  • User Conference
  • Developer Summit
Esri
Tell us what you think.
Copyright © 2021 Esri. | Privacy | Legal