Hi,
I have 2000 files in Marklogic database within a single forest and i want
to find out the unique element name from this database for the whole 2000
files. For this i wrote the below query:-
for $a in //*
return distinct-values($a/local-name()))
but by this i got an error [1.0-ml]
The size of the all files is 90 MB approx.
-- Forwarded message --
From: VISH RAJPUT svishnu.sin...@gmail.com
Date: Mon, Mar 26, 2012 at 11:56 AM
Subject: [1.0-ml] XDMP-EXPNTREECACHEFULL
To: general@developer.marklogic.com
Hi,
I have 2000 files in Marklogic database within a
Hi Vishnu,
Your FLWOR expression won’t return distinct names, since you are applying
the function to each individual name. You should write:
distinct-values(
for $a in //*
return $a
)
Or better:
distinct-values(collection()//*/local-name())
But this still might not
Thanks Geert,
But still it shows *XDMP-EXPNTREECACHEFULL:
distinct-values(collection(ContentAnalysis)//*/local-name()) --
Expanded tree cache full on host* the database overall size is only
90MB i don't think it is so huge data for marklogic
Regards,
Vishnu
On Mon, Mar 26, 2012 at
Hi Vishnu,
90 mb isn’t much indeed, but MarkLogic is configured to keep a low memory
footprint, even if there are 30 concurrent requests. To make that sure, the
tree size limit (look at the database setting in the admin interface) is
usually pretty low. I have 8Gb and still it is set to no more
Thanks Geert,
Is there any alternate solution to find the unique elements within a
database?
Warm Regards,
Vishnu
On Mon, Mar 26, 2012 at 5:55 PM, Geert Josten geert.jos...@dayon.nl wrote:
Hi Vishnu,
90 mb isn’t much indeed, but MarkLogic is configured to keep a low memory
footprint,
Hi Vishnu,
It would help if you could explain why you need that list. But in general
the best option would be to pre-calculate the list I guess. You can save it
as a server-field (xdmp:set-server-field), to keep the list in memory on
each host. But you would need an algorithm to initialize it,
You could try a recursive function like the following. No guarantee it is
100% right, if you have sub elements that have the same names as your root
elements.
xquery version 1.0-ml;
declare function local:find-unique-qnames($found-qnames as xs:QName*) {
let $next-qname :=
hi,
you can loop across each document, grab all the child nodes and put them in a
map.
Thanks and Regards,
Sai.
From: Ryan Dew ryan.j@gmail.com
To: MarkLogic Developer Discussion general@developer.marklogic.com
Sent: Monday, March 26, 2012 9:14 AM
Subject: Re: [MarkLogic Dev General]
Curious there aren’t functions like this tapping into the universal index.
-Brent
From: general-boun...@developer.marklogic.com
[mailto:general-boun...@developer.marklogic.com] On Behalf Of sai shanker
Sent: Monday, March 26, 2012 9:23 AM
To: MarkLogic Developer Discussion
Subject: Re:
Yes, I will try this. I was hoping there was just a flag I was missing on the
options. It seems like something that would be a fairly common use case for
something that's handling user input like this.
From: Clark Richey [mailto:clark.ric...@marklogic.com]
Sent: Friday, March 23, 2012 9:42 PM
It’s a bit off-topic but you can do that easily with BaseX:
Create a DB, load all documents, than:
index:element-names(DB_NAME)
Szabolcs
From: general-boun...@developer.marklogic.com
[mailto:general-boun...@developer.marklogic.com] On Behalf Of Brent Hartwig
Sent: 26 March 2012
Don’t think there is a lexicon for element names. Could make sense though.
I liked the map:map approach, so thought to give it a go. I have a database
with about 400k small docs. The following code ran in a few sec on the
first 1000 docs:
let $elems := map:map()
let $process-docs :=
for
We just upgraded to Marklogic server 5.0-3 and now I am getting this error for
my application. Did anyone face this issue with their application?
500 Internal Server Error
XDMP-UNEXPECTED: (err:XPST0003) Unexpected token syntax error, unexpected
QName_, expecting EmptyTagClose_ or
What does the code in footer.xqy look like?
One bug fix that was made in 5.0-1 was to require quotes around
attribute values in direct element constructor expressions - maybe you
have unquoted attribute values in your program?
John
On 26/03/12 17:22, Khan, Kashif wrote:
We just upgraded
Here is what is in the footer.xqy file
xquery version 1.0-ml;
import module namespace xqmvc = http://scholarsportal.info/xqmvc/core; at
../../system/xqmvc.xqy;
declare variable $data as map:map external;
div class=container
div id=primary_nav
ul
Speaking of bug fixes, the release notes at support.marklogic.com haven't yet
been updated to reflect fixes in 5.0-3.
On Mon, 26 Mar 2012, John Snelson wrote:
What does the code in footer.xqy look like?
One bug fix that was made in 5.0-1 was to require quotes around
attribute values in
I will try this but one more thing that I noticed is that CQ has also
stopped working.
Best Regards,
Kashif Khan
On 3/26/12 1:11 PM, Michael Blakeley m...@blakeley.com wrote:
Try adding some whitespace before the src attribute, as required by
CQ is now Query Console and is available at port 8000/qconsole
It is wildly improved. There's a good document on the community site.
On Mar 26, 2012 11:18 AM, Khan, Kashif kashif.k...@hmhpub.com wrote:
I will try this but one more thing that I noticed is that CQ has also
stopped working.
Eric Others,
After reading more I though you could be correct that all documents
would have to be loaded with Corona. So I tried to load a document using
the example commands but that didn't work. Kept getting a 404. Maybe the
URI path I'm giving it is an issue (e.g.
Dear MarkLogic Community,
In an effort to increase participation in the MarkLogic Community, we will
announce a new Academic License for students and educators on March 27. The
goal of the Academic License is to engage the academic community, educate them
about MarkLogic, and ultimately
21 matches
Mail list logo