Open topic with navigation

# DOCUMENT

The Synchronize action searches the repository one time for each `DOCUMENT` element. The exact query to the repository is determined by the attributes of the `DOCUMENT` element.

The `DOCUMENT` element specifies a `document_name` attribute to identify all documents generated from this definition. You can create multiple `DOCUMENT` elements with different document names.

Attributes | Description
--- | ---
`document_name` | The name assigned within the identifier of any document generated from this definition. This is used to identify documents generated from this element.
`type_pattern` | A comma-separated list of strings to restrict the types of objects that are retrieved. Only business objects with a type matching one or more of the strings are retrieved. The wildcards * and ? can be used.
`where` | An expression string to restrict the documents retrieved. This can be used to restrict the documents that are retrieved by the values of selectable attributes. For example: `where="(name=~~'X_*' || name=~~'Y_*') AND (attribute[Part Code Status]=='XY')"`
`limit` | The maximum number of document updates to process in a single cycle. This attribute is useful for testing purposes.
`node_name` | The name of a metadata field that is created to contain all the metadata added by the child elements. If this is not specified the child metadata is added at the top level. This attribute only adds structure to the metadata and does not affect the metadata itself.
Other attributes | Other attributes that are not reserved are output as metadata in the resulting document.

## Example

The following examples result in identical output. The first example uses the `node_name` attribute:

    <DOCUMENTS>
       <DOCUMENT document_name="mydoc" type_pattern="Part" node_name="mydoc" myfield="value">
          ...
       </DOCUMENT>
    </DOCUMENTS>

The following example does not use the `node_name` attribute:

    <DOCUMENTS>
       <DOCUMENT document_name="mydoc" type_pattern="Part">
          <mydoc>
             <myfield>value</myfield>
             ...
          </mydoc>
       </DOCUMENT>
    </DOCUMENTS>

Result

The following XML metadata is created for every object of type part:

    <mydoc>
       <myfield>value</myfield>
       ...
    </mydoc>

© 2018 Micro Focus or one of its affiliates | Send documentation feedback to Micro Focus Close Send documentation feedback To open the configured email client on this computer, open an email window. Otherwise, copy the information below to a web mail client, and send this email to swpdl.idoldocsfeedback@microfocus.com. We appreciate your feedback! Product: Topic Title: Help Topic: Feedback:

_FT_HTML5_bannerTitle.htm