Yes thanks. 

 

Gary Larsen

Envisn Inc.

508 259-6465

 

From: [email protected]
[mailto:[email protected]] On Behalf Of Danny Sokolsky
Sent: Thursday, October 15, 2015 2:45 PM
To: MarkLogic Developer Discussion
Subject: Re: [MarkLogic Dev General] Data out of sync

 

I think you want to do an fn:doc of the URI, not an xdmp:directory.
xdmp:directory returns all of the documents in that directory, and since
that is not a directory, there ar no documents in the directory and it
returns nothing. 

 

-Danny

 

From: [email protected]
[mailto:[email protected]] On Behalf Of Gary Larsen
Sent: Thursday, October 15, 2015 11:40 AM
To: 'General MarkLogic Developer Discussion'
Subject: [MarkLogic Dev General] Data out of sync

 

Ran into a case where database data seems to be jumbled.  This query returns
a path to a document:

 

let $find :=
"CAMID("default:u:authid=3667487167")/folder[@name='My
Folders']/report[@name='A Test1 - Order Summary']"
let $cq := 
    cts:and-query((
      cts:collection-query('content'),
      cts:element-value-query(xs:QName('searchPath'), $find) 
    ))
for $c in cts:search(doc(), $cq, 'unfiltered')  return xdmp:node-uri($c)

which returns:
/db/netvisn/content/sub120/i01E150D89282419FBAD072EB4992D289.xml

 

But this query has no results:

 

xdmp:directory('/db/netvisn/content/sub120/i01E150D89282419FBAD072EB4992D289
.xml')

 

Ran a reindex on the database but this did not help.  I was thinking about
doing an export and import but in some folders the documents have a
collection assigned and not sure if that can be imported.

 

Any ideas what may be going on?   This is a v5 or v6 database as I've been
reluctant to upgrade and reindex, and things were working great.

 

Thanks,

Gary

 

_______________________________________________
General mailing list
[email protected]
Manage your subscription at: 
http://developer.marklogic.com/mailman/listinfo/general

Reply via email to