[$options as String],
[$query as cts.query?]
) as sem.store
sem:store function defines a set of criteria, that when
evaluated, selects a set of triples to be passed in to
sem:sparql-values as part of
the options argument. The
sem:store constructor queries from
the current database's triple index, restricted by the options and the
cts:query argument (for instance, "triples in documents matching
This function is a built-in.
Options as a sequence of string values. Available options are:
- Values from any fragment should be included.
- Values from document fragments should be included.
- Values from properties fragments should be included.
- Values from locks fragments should be included.
- Word positions should be checked when resolving the query.
- Word positions should not be checked when resolving the query.
- "size=number of MB"
- The maximum size of the memory used to cache inferred triples. This
defaults to the default inference size set for the app-server. If the
value provided is bigger than the maximum inference size set for the
App Server, an error is raised [XDMP-INFSIZE].
- Don't apply the database's default rulesets to the sem:store.
read-write: Read-lock documents containing triples being accessed,
write-lock documents being updated;
write: Only write-lock documents
being updated. Default is
locking=read-write. Locking is ignored in
Only include triples in fragments selected by the |
The triples do not need to match the query, but they must occur in
fragments selected by the query.
The fragments are not filtered to ensure they match the query,
but instead selected in the same manner as
cts:search operations. If a string
is entered, the string is treated as a
cts:word-query of the
Only one of "any", "document", "properties", or "locks" may be specified
in the options parameter. If none of "any", "document", "properties", or
"locks" are specified and there is a
$query parameter, then
the default is "document". If there is no
then the default is "any".
Options for "any", "document", "properties", "locks", "checked", or
"unchecked" must be specified as part of
as part of
var sem = require("/MarkLogic/semantics.xqy");
sem.store(null, cts.wordQuery("Alfa Romeo"));
Returns a sem:store() containg all of the triples that exist in documents
that match a query for "Alfa Romeo".
Copyright © 2017 MarkLogic Corporation. MARKLOGIC is a
registered trademark of MarkLogic Corporation.