Search task
When working in the field, you are often assigned a region to inspect or update existing assets. You can use the Search task to find features within a map extent and by certain search criteria. You can then put the features you find in a work list so that you can visit them later.
The data used in this topic is based on the data model discussed in A sample data model for field data collection.
Using the Search task
On a Windows Mobile device
- Open a project on your field device (see Opening/Closing/Deleting projects for more details).
- Tap Search on the Work List page.
- The Choose an option page appears.Note:
As shown in the screen shot below, if your project administrator has already defined searches for you, they show on the page and you can tap each one to execute and view the results directly (read the Browsing search results section for more information). You may need to provide search criteria for some of those pre-defined searches if required by the project administrator. In addition, you can also create a new search and save it on your device. All pre-defined searches show on this page.
To delete a saved search, use the rocker button to highlight a search, and tap Menu > Delete Search.
- Tap Start New Search to start a new search.
On a Windows device
- Open a project on your field device (see Opening/Closing/Deleting projects for more details).
- On the View Map page, tap Tasks > Search.
- The Search page appears.Note:
As shown in the screen shot below, if your project administrator has already defined searches for you, they show on the page and you can tap each one to view the results directly (read the Browsing search results section for more information). You may need to provide search criteria for some of those pre-defined searches if required by the project administrator. In addition, other searches you created and saved show on this page.
To delete a saved search, tap Edit and tap the search to delete it. When finished, tap Done.
- Tap New Search to start a new search.
Choosing a feature type to search
The first step in defining your search is to choose the feature type you are looking for. When your project administrator authors your project, they define the feature types that can be searched when using the Search task. If you cannot find the feature type you have been assigned to inspect, contact your project administrator.
The Choose Feature Type page (Windows Mobile device) or Search—Choose a feature type page (Windows device) contains a list of feature types you can search for. Scroll down the page and tap the feature type you want to search against.
In the ArcGIS application running on a Windows Mobile device, if you know the name of the feature type you want to search for, you can narrow down the list of feature types by typing the feature type name in the search bar at the top of the page.
A map layer may have several feature types (for example, a layer named Damaged assets may have the feature types Critically damaged, Fairly damaged, and so on). To better organize them, you can group them by their layers. To do so, tap Menu > Group By Layer. If you want to search against all feature types of the map layer instead of a feature type, tap the layer's name (Windows Mobile device) or All Types (Windows device) and the search spans all feature types, as shown in the image below.
After grouping feature types by map layers, you can further narrow the list by tapping Menu > Choose Layers (Windows Mobile device) or Menu > Filter Layers (Windows device), uncheck the map layers that you don't want to see in the list, then tap OK.
If you're using a Windows Mobile device, after you've tapped a feature type to search against, the application prompts you to see the search results directly or to add search criteria. To see the results directly, tap Find Now and read the Browsing search results section. To add search criteria, tap Refine Search and read the next section.
Defining the search area and search criteria
After you choose a feature type, you can specify a search area and define search queries on the Setup Search Criteria page.
- On the Setup Search Criteria page, you can tap the Search Area button and reset the search area to the current map extent, entire map, or custom extent.
- If you select custom extent in the last step, the Choose Extent page appears with a map view. Zoom in/out and pan to the area you want to search against, then tap Accept (Windows Mobile device) or Ok (Windows device) to return to the Setup Search Criteria page.
- To add a search query, tap Add Criteria on the Setup Search Criteria page.
- The Choose Field (Windows Mobile device) or the Add Criteria: Choose Field (Windows device) page shows. Tap the field you want to use to create a search criteria.
- The next page shows a list of operators based on how you can create expressions, such as Assessment Date (a date field) in the past 48 hours, Occupant Name (a text field) contains Taylor or Number of Floors (a numeric field) less than or equals 5.Tip:
Your project administrator can attach business rules to certain fields. If you pick a field that has an associated rule, a drop-down list appears and shows the valid values for the rule. For example, the field Is there basement? may show Yes, No, and Unknown as a list of values. This makes it easier for field workers to pick from the list instead of typing on the device.
- After you have added a criteria, it shows on the Setup Search Criteria page. Repeat steps 1-5 to add more criteria if necessary.
- If you want to edit or delete saved criteria:
- On a Windows Mobile device, tap the criteria directly, tap Edit, then follow step 5 to edit it or tap Remove to delete it.
- On a Windows device, tap the criteria directly, and follow step 5 to edit it, or tap Edit, then tap a criteria to delete it.
- If you want to save the search for later use, read the Saving the search criteria section. If you want to view the results directly, tap Show Results and read the Browse search results section.
Saving the search criteria
You can save a search defined through the steps in the last section. This enables you to execute your query multiple times without having to redefine it. To save the search criteria:
- Follow the steps in the last section to define the search criteria.
- When done, tap Menu > Save Search Criteria (Windows Mobile device) or Menu > Save Search (Windows device) at the bottom of the Setup Search Criteria page.
- On the next page, enter a name for the search (such as Undamaged assets) and tap OK (Windows Mobile device) or Save (Windows device).Note:
If you have already saved this search, you are prompted to overwrite the existing one or save it as a new one with a different name.
- When your search is saved, you are redirected to the Setup Search Criteria page. If you're using a Windows device, the title of the Setup Search Criteria page becomes the name of the search.
Browsing search results
After you have defined a search, you can view the results on the map and their attributes on the attribute page.
If you're using a Windows Mobile device, the number of features found show at the bottom left of the Setup Search Criteria page.
- To browse the features you have found, tap Show Results on the Setup Search Criteria page.
- The Search Results page appears with a list of features found.
- If you're using a Windows Mobile device, you can view a feature's attribute by tapping the feature and tapping View Feature to see its attributes. You can also view a feature on the map by tapping the feature and tapping Browse On Map. On the map view, a feature shows as a blue pin if it's a point. If it's a line or a polygon, it highlights in cyan. Note that on the bar near the bottom of the page, you can tap the carets to switch to another feature.
- If you're using a Windows device, the features found show and also highlights on the map. You can switch from one feature to another by tapping the feature directly. The selected feature renders in orange with a red outline. You can also see a feature's attribute by tapping the Attributes tab or see attachments by tapping the Attachment tab.
Working on searched features
You can perform various operations to individual searched features or to all results.
Operations on individual search results
From the search results page, you can perform various operations to individual features including:
- Viewing a feature on the map and view its attributes (see the Browsing search results section)
- Editing a feature (see Updating features using Windows Mobile device and Updating features using Windows device)
- Deleting a feature
- Adding a feature to work list
- Navigating to a feature (available in Windows Mobile device only) (see Using GPS in Windows Mobile devices)
The following screen shots show the operations you can perform to a search result:
If you're using a Windows Mobile device, tap a feature directly from the search results to see the available operations. If you're using a Windows device, tap a feature on the Search Results list, then tap the button.
Operations on all search results
You can also add all search results to the work list or refresh the search results after updating a feature .
To add all search results to the work list, tap Menu > Add All to Work List on the search results page.
Additionally, you can refresh the search results if you edit a feature that does not meet a search criteria, or if your edits on other features meets the criteria in the search results. To do so, tap Menu > Refresh Results. The features that don't meet the search criteria are removed from the list, and if there are other features that now meet the search criteria, they show in the results list.
Refining an existing search
You can update the search area or search criteria for an existing search by following the steps below:
- Open the Choose an option page (Windows Mobile device) or Search page (Windows device) and tap a saved search, or follow the sections above to define a search on-the-fly.
- On the Search Results page, tap Refine Search.
- The Setup Search Criteria page shows. Follow the steps in the Defining the search area and search criteria section to refine the search criteria.