Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Section
titleSummary

If you need to constrain the search result to documents with a given ancestor, you can take advantage of the artificial properties  like AncestorNames and AncestorIds.


Section
titleUsage Examples

The following examples can be used with macros that execute searches like the Display Table Macro or the Transclude Documents Macro.

Section
titleSubtree Search

Suppose you have a Component document "Server" with documents for sub components. Now you need to list all documents of type View that are associated with the component or any of its subordinate documents.

To limit your search to all documents that have the document named "Server" as their ancestor add

Code Block
languagetext
$<AncestorNames>=[Server]

to your where clause.

To filter on the doctype View, you need to append another constraint so that the final where clause looks like this:

Code Block
languagetext
$<AncestorNames>=[This Root Page] AND Doctype=view



Section
titleSearch for own Descendants

If you need to list the descendants of a document on that document, you can use the AncestorIds property.This is especially helpful for template authors since the ID is unique, whereas the name might not be.

The projectdoc Toolbox adds the page identifier as artificial property. So the where clause for this search looks like this:

Code Block
languagetext
$<AncestorIds> = [${Page ID}]



...

Section
titleResources

Here is more information related to searches with the PDAC1.

Tour
render-as-definition-listtrue
replace-title-with-nametrue


TitleShort Description
Search Tips
Artificial Properties



...