xdmp:forest-counts( $forest-id as xs:unsignedLong*, [$show-elements as xs:string*], [$options as xs:string*] ) as element(forest-counts)*
Returns detailed forest statistics for a given forest
.
This built-in may require significantly more processing
time than xdmp:forest-status
.
http://marklogic.com/xdmp/privileges/counts
The structure of the data returned is as follows:
forest-id
forest-name
current-time
error
rebalancer-error
stands-counts
This is a complex element with the following element children:
stand-counts
This is a complex element with the following element children:
stand-id
path
active-fragment-count
nascent-fragment-count
deleted-fragment-count
document-count
directory-count
all-query-rolesets-fragment-count
This is a complex element with the following element children:
query-rolesets-fragment-count
This is a complex element with the following element children:
query-rolesets-id
fragment-count
reindex-refragment-fragment-count
reindex-refragment-rate
forced-reindex-fragment-count
reindex-fragment-count
reindex-previous-versions-count
reindex-stemmed-searches-count
reindex-word-searches-count
reindex-one-character-searches-count
reindex-two-character-searches-count
reindex-three-character-searches-count
reindex-fast-phrase-searches-count
reindex-fast-case-sensitive-searches-count
reindex-fast-element-word-searches-count
reindex-fast-element-phrase-searches-count
reindex-fast-element-character-searches-count
reindex-fast-element-trailing-wildcard-searches-count
reindex-word-positions-count
reindex-scaled-log-tf-normalization-count
reindex-unscaled-log-tf-normalization-count
reindex-element-word-positions-count
reindex-element-value-positions-count
reindex-attribute-value-positions-count
reindex-field-value-searches-count
reindex-field-value-positions-count
reindex-three-character-word-positions-count
reindex-triple-index-count
reindex-triple-positions-count
reindex-trailing-wildcard-searches-count
reindex-trailing-wildcard-word-positions-count
reindex-fast-diacritic-sensitive-searches-count
reindex-word-lexicon-count
reindex-binary-threshold-count
reindex-deleted-stemmed-searches-count
reindex-deleted-word-searches-count
reindex-deleted-one-character-searches-count
reindex-deleted-two-character-searches-count
reindex-deleted-three-character-searches-count
reindex-deleted-fast-phrase-searches-count
reindex-deleted-fast-case-sensitive-searches-count
reindex-deleted-fast-element-word-searches-count
reindex-deleted-fast-element-phrase-searches-count
reindex-deleted-fast-element-character-searches-count
reindex-deleted-fast-element-trailing-wildcard-searches-count
reindex-deleted-word-positions-count
reindex-deleted-element-word-positions-count
reindex-deleted-element-value-positions-count
reindex-deleted-field-value-searches-count
reindex-deleted-field-value-positions-count
reindex-deleted-attribute-value-positions-count
reindex-deleted-three-character-word-positions-count
reindex-deleted-triple-index-count
reindex-deleted-triple-positions-count
reindex-deleted-trailing-wildcard-searches-count
reindex-deleted-trailing-wildcard-word-positions-count
reindex-deleted-fast-diacritic-sensitive-searches-count
reindex-uri-lexicon-count
reindex-deleted-uri-lexicon-count
reindex-collection-lexicon-count
reindex-deleted-collection-lexicon-count
reindex-element-word-query-throughs
This is a complex element with the following element children:
reindex-element-word-query-through
This is a complex element with the following element children:
namespace-uri
localname
reindex-fragment-count
fragment-count
reindex-phrase-throughs
This is a complex element with the following element children:
reindex-phrase-through
This is a complex element with the following element children:
namespace-uri
localname
reindex-fragment-count
fragment-count
reindex-phrase-arounds
This is a complex element with the following element children:
reindex-phrase-around
This is a complex element with the following element children:
namespace-uri
localname
reindex-fragment-count
fragment-count
reindex-range-element-indexes
This is a complex element with the following element children:
reindex-range-element-index
This is a complex element with the following element children:
namespace-uri
localname
scalar-type
reindex-fragment-count
fragment-count
reindex-range-field-indexes
This is a complex element with the following element children:
reindex-range-field-index
This is a complex element with the following element children:
field-name
scalar-type
reindex-fragment-count
fragment-count
reindex-range-path-indexes
This is a complex element with the following element children:
reindex-range-path-index
This is a complex element with the following element children:
path-expression
scalar-type
reindex-fragment-count
fragment-count
reindex-range-element-attribute-indexes
This is a complex element with the following element children:
reindex-range-element-attribute-index
This is a complex element with the following element children:
parent-namespace-uri
parent-localname
namespace-uri
localname
reindex-fragment-count
fragment-count
reindex-deleted-range-indexes
This is a complex element with the following element children:
fragment-count
reindex-element-word-lexicons
This is a complex element with the following element children:
reindex-element-word-lexicon
This is a complex element with the following element children:
namespace-uri
localname
reindex-fragment-count
fragment-count
reindex-element-attribute-word-lexicons
This is a complex element with the following element children:
reindex-element-attribute-word-lexicon
This is a complex element with the following element children:
parent-namespace-uri
parent-localname
namespace-uri
localname
reindex-fragment-count
fragment-count
reindex-all-deleted-word-lexicons
This is a complex element with the following element children:
fragment-count
reindex-geospatial-element-indexes
This is a complex element with the following element children:
reindex-geospatial-element-index
This is a complex element with the following element children:
namespace-uri
localname
reindex-fragment-count
fragment-count
reindex-geospatial-element-child-indexes
This is a complex element with the following element children:
reindex-geospatial-element-child-index
This is a complex element with the following element children:
parent-namespace-uri
parent-localname
namespace-uri
localname
reindex-fragment-count
fragment-count
reindex-geospatial-element-pair-indexes
This is a complex element with the following element children:
reindex-geospatial-element-pair-index
This is a complex element with the following element children:
parent-namespace-uri
parent-localname
latitude-namespace-uri
latitude-localname
longitude-namespace-uri
longitude-localname
reindex-fragment-count
fragment-count
reindex-geospatial-element-attribute-pair-indexes
This is a complex element with the following element children:
reindex-geospatial-element-attribute-pair-index
This is a complex element with the following element children:
parent-namespace-uri
parent-localname
latitude-namespace-uri
latitude-localname
longitude-namespace-uri
longitude-localname
reindex-fragment-count
fragment-count
reindex-geospatial-region-indexes
This is a complex element with the following element children:
reindex-geospatial-region-index
This is a complex element with the following element children:
path-expression
coordinate-system
reindex-fragment-count
fragment-count
reindex-deleted-geospatial-region-indexes
This is a complex element with the following element children:
fragment-count
reindex-protected-paths
This is a complex element with the following element children:
reindex-protected-path
This is a complex element with the following element children:
path-expression
reindex-fragment-count
fragment-count
reindex-deleted-protected-paths
This is a complex element with the following element children:
fragment-count
reindex-tde-templates
This is a complex element with the following element children:
reindex-tde-template
This is a complex element with the following element children:
tde-template
reindex-fragment-count
fragment-count
reindex-deleted-tde-templates
This is a complex element with the following element children:
fragment-count
refragment-document-count
refragment-fragment-roots
This is a complex element with the following element children:
refragment-fragment-parent
This is a complex element with the following element children:
namespace-uri
localname
refragment-document-count
document-count
refragment-fragment-parents
This is a complex element with the following element children:
refragment-fragment-parent
This is a complex element with the following element children:
namespace-uri
localname
refragment-document-count
document-count
refragment-new-fields
This is a complex element with the following element children:
refragment-new-field
This is a complex element with the following element children:
field-name
refragment-document-count
document-count
refragment-modified-fields
This is a complex element with the following element children:
refragment-modified-field
This is a complex element with the following element children:
field-name
refragment-document-count
document-count
refragment-removed-configurations
This is a complex element with the following element children:
refragment-document-count
reindex-reverse-searches-fragment-count
rebalance-fragment-counts
This is a complex element with the following element children:
rebalance-fragment-count
This is a complex element with the following element children:
rebalance-destination
fragment-count
rebalance-rate
xdmp:forest-counts(xdmp:forest("Documents")) => <forest-counts xmlns="http://marklogic.com/xdmp/status/forest"> <forest-id>12434840716430044697</forest-id> <current-time>2007-02-16T19:00:00.708-08:00</current-time> <stands-counts> <stand-counts> <stand-id>15174447282968484759</stand-id> <path>c:\Program Files\MarkLogic\Data\Forests\Documents\00000016</path> <active-fragment-count>146</active-fragment-count> <nascent-fragment-count>0</nascent-fragment-count> <deleted-fragment-count>0</deleted-fragment-count> </stand-counts> </stands-counts> <document-count>67</document-count> <directory-count>3</directory-count> </forest-counts>
(: only calculate the document count :) xdmp:forest-counts(xdmp:forest("Documents"), ("document-count")) => <forest-counts xmlns="http://marklogic.com/xdmp/status/forest"> <forest-id>11656884323633926637</forest-id> <forest-name>Documents</forest-name> <current-time>2008-03-18T16:22:34.082-07:00</current-time> <document-count>1070</document-count> </forest-counts>
(: force everything to be calculated :) xdmp:forest-counts(xdmp:forest("Documents"), "*") => the full output of xdmp:forest-counts