[MarkLogic Dev General] can I also set a directory-property?
Mike Sokolov
sokolov at ifactory.com
Wed Jun 6 09:37:55 PDT 2007
It is possible to retrieve directory properties using
xdmp:document-properties, isn't it? At least I have noticed that some
properties returned from that function include the <prop:directory />
element. Isn't it also possible to set directory properties?
Michael Blakeley wrote:
> Edgar,
>
> Note that xdmp:directory-properties() does not return the properties
> of a directory. Instead, that function returns the properties of the
> documents in a directory. See
> http://developer.marklogic.com/pubs/3.2/apidocs/Extension.html#directory-properties
> - "Returns a sequence of properties documents, one for each document
> in the specified directory that has a corresponding properties document."
>
> The Developer's Guide has more information about properties.
>
> You might create a metadata document in each directory, using a
> well-known URI and element-root (and possibly a collection). You might
> also set the desired property on document(s) in your directory, and
> use xdmp:directory-properties() to query for it.
>
> -- Mike
>
> Schouten, Edgar J. (RB-NL) wrote:
>> Hi All,
>>
>> I have a directory-stucture with a tree consisting of Magazine Titles,
>> containing Volumes, containing Issues, containing Articles (an article
>> is an xml-file)
>> All the Issues have a publicationDate that is identical for all Articles
>> in that Issue.
>>
>> I have seen that directories can have properties as well.
>>
>> xdmp:directory-properties( $uri as xs:string, [$depth as xs:string] ) as
>> document-node()*
>>
>> My question: can I also set a directory-property?
>>
>> I would like to add a <publicationDate>YYYY-MM-DD</publicationDate> to
>> the Issue-folder
>>
>> Regards
>> EdgarS
>>
>>
>>
>>
>>
>> ------------------------------------------------------------------------
>>
>> _______________________________________________
>> General mailing list
>> General at developer.marklogic.com
>> http://xqzone.com/mailman/listinfo/general
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> General mailing list
> General at developer.marklogic.com
> http://xqzone.com/mailman/listinfo/general
>
More information about the General
mailing list