Selecting Using the Find... Command in Advanced Mode

The Advanced search mode lets you compose more precise queries using a combination of search criteria, as well as the And, Or, and Except operating signs.

Any information you enter in the General tab is also available in the Advanced tab, as well as the name of the last package in which you performed a search.

This task shows you how to:


Before you begin:
  • You can open multiple Find dialog boxes at the same time.
  • When searching for attributes, make sure you are in an authoring window. Otherwise, there are no results.
  • In a navigation window, only search for Title or Name attributes. You cannot search for other attributes because it depends on the internal state of your session (that is not controlled by the end user.)
  • You can record and run your search queries using macros. The recorded macro is stored in a CATScript file containing a transformat query, which means that you can run the query whatever the session language. For more information, see Running and Editing Macros.

Run an Advanced Search for Specific Attributes

You can search for specific attributes such as the color or the diameter of an object. You can also combine search criteria to run more complex queries.

  1. Press Ctrl+F.
  2. In the Find dialog box, click the Advanced tab.
  3. In the App list, select the Product Structure package.
  4. In the Attribute list, select an attribute.

    If you are searching for a character string whose value is empty, leave the box in the Attribute Criterion dialog box empty to have the following query syntax:

    ''.type.attribute=

    where:

    • '' is the package in which you are performing your search.
    • type is the type of the object containing the string you are searching for.
    • attribute is the attribute containing the empty string.

    For example:

    'Product Structure'.Product.Product Description=

  5. Click OK, and then click the operating sign of your choice (And, Or, Except) to combine several search criteria and refine your query.
  6. In the Attribute list, select the Color attribute, and then choose a color.
  7. Click OK, and then click Find to run the search.

    Tip: Click Find and Select to run the search and select automatically the objects that have been found.

    When running a query with a color as search criterion, you can either:

    • Pick a color among the 16 colors available.
    • Pick a color among the 48 colors available by default in the Basic Color area of the Color chooser. The Color chooser is displayed when you click More Colors... at the end of the list.
    • Pick a color among the 16 custom colors available in the Custom Colors area of the Color chooser.
    • If this color is one of the 48 colors available by default, enter its name directly in the Composed query box.

  8. From the list, select a package, and then a type.
  9. Select an attribute for the type, and then enter a value.
    Depending on the attribute you select, the Attribute Criterion dialog box:
    • Displays a list of attributes.
    • Lets you choose a Boolean attribute (such as TRUE or FALSE) if you are searching for a threaded hole, for example.
  10. Select an operating sign from the list, and then enter a value. You can use the default value * as a wildcard.

    For example, select the = operating sign and the value 4mm; 10mm to search for any element whose diameter is comprised between 4mm and 10mm.

    The number of operating signs displayed in the list depends on the attribute you chose. Below is an exhaustive list of the available operating signs:

    • =
    • != (different)
    • <
    • <=
    • >
    • >=

  11. To modify the query, enter a new query in the editor.
    For example:

    'Part Design'.Sketch.name!=*2, or 'Part Design'.Sketch - name=*2

    Means that you search for all sketches except those whose names end with 2.

    Another example:

    'Part Design'.Hole.name=*1 & 'Part Design'.Hole.Diameter<50mm

    Means that you search for all holes whose names end with 1 and whose diameters are lower than 50 mm.

    Tip:
    • You can add brackets, and group queries together.
    • You can copy one of the above-detailed queries, paste it directly to the query editor, and then start the search.
  12. Click OK, and then click Find to run the search.
    Important: If you select the Drafting package, you can search for specific attributes (such as dimensions), or elements of type Geometry (such as 2D lines or 2D curves). See Drafting User's Guide: Working with Annotations: Performing an Advanced Search for more information.

Run an Advanced Search for Dynamic Attributes

The Product Structure app lets you search for elements that possess certain properties (called "dynamic attributes") you defined for a product.

You assign properties to products (and to parts in products) by selecting an element from the Product list. For more information, see Product Structure Design: Editing Properties: Editing Product Properties.

  1. In the App list, select Product Structure, and in the Type box, select Product DS.
    The query syntax is displayed as follows in the editor:

    'Product Structure'.Product DS.'

  2. Edit the query manually in the editor to add a search for a more specific attribute.

    For example:

    'Product Structure'.Product DS.'Real.2'=12.3 Means that you search for an attribute named Real.2 with a value equal to 12.3.
    'Product Structure'.Product DS.'Real.2'='10;40' Means that you search for an attribute named Real.2 with a value comprised between 10 and 40.
    'Product Structure'.Product DS.'Real.2'!='12;12.25' Means that you search for an attribute named Real.2 with a value different from 12 and 12.25.
    'Product Structure'.Product DS.'Real.2'<13 Means that you search for an attribute named Real.2 with a value lower than 13.
    Important: You can also search for specific attributes, such as materials. For example, to search for the "Steel" material, enter the following query:

    'Product Structure'.Material.Name=Steel

  3. Click OK, and then click Find to run the search.

Search Using a Combination of Search Criteria

You can use And, Or, and Except to combine several search criteria, and refine your query.

  1. In the App list, select Part Design.
  2. In the Type list, select Hole.
  3. In the Attribute box, select Name, and then enter the value *1 for the name.
  4. Click Or.
  5. In the Type box, select Pad.
  6. In the Attribute box, select Name, and then enter the value *1 for the name.
    The query syntax is displayed as follows in the editor:

    'Part Design'.Hole.Name=*1+'Part Design'.Pad.Name=*1.

    In this example, we are searching for holes and pads created using the Part Design package, or whose names end with 1.

    Warning: When running a search:
    • The & character represents the And operator.
    • The + character represents the Or operator.
    • The - character represents the Except operator.

    When used in a query, these characters must be written between quotes, for example:

    "Name=*X-Y*" searches for objects whose name ends with X but does not start with Y.

    "Name=X*'-'Y*" searches for objects whose names contains the X-Y string.

    For more information about the search language, see Using the Search Language.

  7. In the Look list, specify the scope option.
  8. Click Find to run the search.
    A list containing the search results is displayed at the bottom of the Find dialog box.

    Tip: Click Add to favorites... to add your query to your favorites. For more information, see Selecting Using the Find... Command in Favorites Mode.

  9. Click Select to select the objects in the 3D area and in the tree.

    There is no need to do this if you click Find and Select to run your search.

  10. To modify the query, enter a new query in the editor. For example:
    'Part Design'.Sketch.name!=*2, or 'Part Design'.Sketch - name=*2

    means that you search for all sketches except those whose names end with 2.

    'Part Design'.Hole.name=*1 & 'Part Design'.Hole.Diameter<50mm

    means that you search for all holes whose names end with 1 and whose diameters are lower than 50 mm.

    Tip: You can copy one of the above-detailed queries, paste it directly to the query editor, and then start the search.