Integration Rules Setup
Custom Queries
This task shows you how to customize query
operations. Customizing queries consists of choosing the query criteria
which best meet your needs. The procedure described here applies to both query types, that is to queries by latest revisions only and to interactive queries. This means that once you have followed the steps as explained here, both query types are affected by your customization. For reference information about queries, see Identifying SmarTeam Documents. |
|||||||||||||||||||||||||||||||||||||||
Properties and Related AttributesThe table below provides a list of all the properties and related attributes which you can set for customizing queries:
Notes
For reference information about the Integration Tools Setup Utility, see the SmarTeam documentation. |
Queries are used to map objects loaded in CATIA to objects existing in the SmarTeam database. The SmarTeam reconciliator provides one query, Latest available revision, which can be launched without an interface or interactively. Custom queries can be defined based on any of the standard (base DS) queries. Custom queries can define the parameters that make up the query and/or supply default values for the query parameters. Only parameters defined in the Integration Rules Setup are available for custom queries. The following steps summarize how the custom query works:
To produce a custom query you will need to:
|
||||||||||||||||||||||||||||||||||||||||||||||||||||
In the CATReconcileCustomize.xml file, each custom query will define, at a minimum, the query name, the standard query on which it is based and the xslt (Extensible Stylesheet Language Transformations) files (In/Out). Example of a Custom Query definitionThis sample CATReconcileCustomize.xml file defines two custom queries: UserCriterion_1 and UserCriterion_2. Both are based on the Interactive-Latest Available Revision standard query. All specify the same In/Out xslt files: UserCriterionIn.xsl and UserCriterionOut.xsl.
How to Use a Custom Query in the Global Query/ Global SetThe custom queries you develop can be incorporated in the Global Query and/or Automatic Preselection Global Set by editing the xml that describes the parameters of this global set. To do this, modify the following file located in: UNIX: <unload_dir>/<os>_a/reffiles/SuppChain MS-Windows: <unload_dir>\<os>_a\reffiles\SuppChain For Global Query: CATPDMAutoRulesValuator_GlobalQueryXMLForm_TeamPDM.xml For Automatic Preselection: CATPDMAutoRulesValuator_AutoPreselectionXMLForm_TeamPDM.xml Add a line for each custom query in the
Defining the In/Out XSLT FilesEach of the standard queries is defined by an xml file which describes all the available attributes for the query. When you are mapping objects in the reconciliator and you select a particular query the xml file defining all the attributes is used to create the query displayed. |
||||||||||||||||||||||||||||||||||||||||||||||||||||
To assist you in defining your own custom queries, the environment variable REC_Display_CustomCriterion=1 can be set to display (in standard output) the xml for any query in the reconciliator.
To create a custom query, you will need to create two xslt files
|