Wolfgang Meier | 1 Dec 09:49 2006
Picon

Re: XQuery (sandbox) and declare variable - err:XQST0049

> I'm trying to use variables in my XQuery:
>
> ---XQuery--BEGIN-----------------------------------------
>
> declare variable $foo as xs:integer := 7;
>
> //*
> ---XQuery--END-----------------------------------------
>
> But I get the following error: "org.exist.xquery.XPathException:
> err:XQST0049: It is a static error if more than one variable declared
> or imported by a module has the same expanded QName. Variable: foo
> [at line 1, column 40]"

This only happens with the sandbox. If you execute your query in the
Java admin client, all will be ok. The sandbox is itself written in
XQuery, so we are executing an XQuery from within an XQuery. This may
cause problems sometimes, especially with prolog expressions. I'll try
to fix this.

Wolfgang

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Pierrick Brihaye | 1 Dec 09:56 2006
Picon

Re: XQuery (sandbox) and declare variable - err:XQST0049

Hi,

Wolfgang Meier a écrit :

> This only happens with the sandbox. If you execute your query in the
> Java admin client, all will be ok. The sandbox is itself written in
> XQuery, so we are executing an XQuery from within an XQuery. This may
> cause problems sometimes, especially with prolog expressions. I'll try
> to fix this.

I've just started working on this :-) It looks like the cause is 
util:eval(), which reuses the outer context.

If that helps...

--

-- 
Pierrick Brihaye, informaticien
Service régional de l'Inventaire / DRAC Bretagne
mailto:pierrick.brihaye <at> culture.gouv.fr / tél : +33 (0)2 99 29 67 78
Avez-vous lu http://usenet-fr.news.eu.org/fr-chartes/rfc1855.html ?

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Adam Retter | 1 Dec 10:07 2006
Picon

Re: Cursor like functionality

Sorry, I dont understand how what you are asking for below is any
different in functionality and memory requirements from what I have
suggested.

Thanks Adam.

On Thu, 2006-11-30 at 09:49 -0800, Hank Ratzesberger wrote:
> Yes, thanks, I considered this, but the potential result set 
> is megabytes.  
> 
> As it happens, these elements have a child with a unique ID,
> so I could cache the "ev-id" element and go back and get the 
> whole element one at a time //myNode[ev-id='an-id'] , but 
> there is some overhead to this also, even with an index.
> 
> So, without yet being familiar with the internals, I wonder 
> if the idea of persisting a query result for the life of a
> session, so that _start and _howmany work just like a cursor
> on subsequent calls -- if the idea has been discussed.
> 
> If the url escaped _query matches an existing, and an _start
> parameter is present, then, the persisted result set is 
> used with no need to re-evaluate the query.
> 
> Cheers,
> Hank
> 
> 
> ----- Original Message ----- 
> From: "Adam Retter" <adam.retter <at> devon.gov.uk>
(Continue reading)

Wolfgang Meier | 1 Dec 10:07 2006
Picon

Re: Persist the cache?

> To deal with inital query performance as the cache gets populated I initally
> thought of running some queries at startup.
>
> Another alternative may be to persist the contents of the cache at shutdown
> and load the cache from the file (if it exists) at startup.  Does that make
> any sense?

Well, the cache just caches the pages from the btrees that live in the
.dbx files. Storing the entire cache into an additional file doesn't
make much sense. Instead, you could simply save the page numbers of
all pages in the cache, then refill the cache with those pages on
startup.

> If so, do you have any hints on where shutdown lives, how to reference the
> cache, and is the cache serializable?

Method BrokerPool.shutdown() is responsible for shutting down the db
(class BrokerPool represents the database instance). The class also
has a method

CacheManager getCacheManager();

CacheManager has a reference to all caches currently used by the .dbx
files (every .dbx file uses two caches, one for btree and one for data
pages). You thus need to extend CacheManager to iterate through all
caches and write out their page numbers.

Wolfgang

-------------------------------------------------------------------------
(Continue reading)

Wolfgang Meier | 1 Dec 10:15 2006
Picon

Re: Cursor like functionality

> Yes, thanks, I considered this, but the potential result set
> is megabytes.

It depends: if the result set references nodes stored in the database,
eXist will just keep pointers to these nodes and memory consumption
will remain within bounds. However, if the result set contains XML
fragments that were constructed within the query, storing them in the
session might really not be a good idea.

Wolfgang

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Bertucci, Eve | 1 Dec 10:28 2006

need help for basic request in a collection !

Hello,

 

I have created a collection /db/nrssbycp and I have put some documents in it.

I don’t manage to do a request in it.

The structure of my documents is:
<nrss>
<channel>
 <title>blabla</title>
</channel>
<nrss>

 And my query is: collection(“/db/nrssbycp”)/nrss/channel/title
I tried to execute it from the graphical interface and from the shell and there is no answer. I also tried with fn:collection.

Please can somebody help me?

Thanks

Eve

 

 

***********************************************************************************
Information contained in this email message is confidential and may be privileged, and is intended only for use of the individual or entity named above. If the reader of this message is not the intended recipient, or the employee or agent responsible to deliver it to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please immediately notify the postmaster <at> nds.com and destroy the original message.
***********************************************************************************
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Exist-open mailing list
Exist-open <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/exist-open
Oystein Reigem | 1 Dec 10:54 2006
Picon
Picon

Re: need help for basic request in a collection !

Eve,
<!-- /* Style Definitions */ p.MsoNormal, li.MsoNormal, div.MsoNormal {margin:0cm; margin-bottom:.0001pt; font-size:12.0pt; font-family:"Times New Roman";} a:link, span.MsoHyperlink {color:blue; text-decoration:underline;} a:visited, span.MsoHyperlinkFollowed {color:purple; text-decoration:underline;} p {mso-margin-top-alt:auto; margin-right:0cm; mso-margin-bottom-alt:auto; margin-left:0cm; font-size:12.0pt; font-family:"Times New Roman";} span.EmailStyle17 {mso-style-type:personal-compose; font-family:Arial; color:windowtext;} <at> page Section1 {size:595.3pt 841.9pt; margin:70.85pt 70.85pt 70.85pt 70.85pt;} div.Section1 {page:Section1;} -->

Hello,

 

I have created a collection /db/nrssbycp and I have put some documents in it.

I don’t manage to do a request in it.

The structure of my documents is:
<nrss>
<channel>
 <title>blabla</title>
</channel>
<nrss>

 And my query is: collection(“/db/nrssbycp”)/nrss/channel/title
I tried to execute it from the graphical interface and from the shell and there is no answer. I also tried with fn:collection.

As the query is rendered in your mail the quotes are wrong. They should both be straight ". But I assume they were right when you tried the query, because else you would have got an error message.

(((And the end tag in the data should be </nrss>, not <nrss>.)))

Your query will fail if <nrss> is not the root element of your documents, or you put your documents in a subcollection of /db/nrssbycp.

- Øystein -

Please can somebody help me?

Thanks

Eve

 

 

***********************************************************************************
Information contained in this email message is confidential and may be privileged, and is intended only for use of the individual or entity named above. If the reader of this message is not the intended recipient, or the employee or agent responsible to deliver it to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please immediately notify the postmaster <at> nds.com and destroy the original message.
***********************************************************************************
------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Exist-open mailing list Exist-open <at> lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/exist-open


-- Øystein Reigem, The department of culture, language and information technology (Aksis), Allegt 27, N-5007 Bergen, Norway. Tel: +47 55 58 32 42. Fax: +47 55 58 94 70. E-mail: <oystein.reigem <at> aksis.uib.no>. Home tel: +47 56 14 06 11. Mobile: +47 97 16 96 64. Home e-mail: <oreigem <at> broadpark.no>. Aksis home page: <www.aksis.uib.no>.
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Exist-open mailing list
Exist-open <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/exist-open
Pierrick Brihaye | 1 Dec 13:15 2006
Picon

Re: Trigger

Hi,

Frank Hölting a écrit :

> exeption:
> org.xmldb.api.base.XMLDBException: java.lang.NullPointerException
> 
> 	at org.exist.xmldb.RemoteCollection.store(RemoteCollection.java:501)

This is a client stack trace. It won't help up in getting the valuable 
information, which should be recorded in the server's logs.

Cheers,

--

-- 
Pierrick Brihaye, informaticien
Service régional de l'Inventaire / DRAC Bretagne
mailto:pierrick.brihaye <at> culture.gouv.fr / tél : +33 (0)2 99 29 67 78
Avez-vous lu http://usenet-fr.news.eu.org/fr-chartes/rfc1855.html ?

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Bertucci, Eve | 1 Dec 14:29 2006

OutOfMemoryError when trying to launch client or shutdown

Hello,

 

I’ve had an outofmemory error when trying to delete a document from a collection.

Since then, I have the outofmemory when I try to launch the client or shutdown the server.

What should I do?

How can I avoid these errors (for the OutOfMemoryError when deleting the doc, I had –Xmx equals to 1 Go and inserting the same document had caused no problem)?

Thanks

 

Eve

 

***********************************************************************************
Information contained in this email message is confidential and may be privileged, and is intended only for use of the individual or entity named above. If the reader of this message is not the intended recipient, or the employee or agent responsible to deliver it to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please immediately notify the postmaster <at> nds.com and destroy the original message.
***********************************************************************************
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Exist-open mailing list
Exist-open <at> lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/exist-open
Leif-Jöran Olsson | 1 Dec 15:36 2006
Picon

Re: OutOfMemoryError when trying to launch client or shutdown


----- Ursprungligt meddelande -----

> How can I avoid these errors (for the OutOfMemoryError when deleting the
> doc, I had –Xmx equals to 1 Go and inserting the same document had
> caused no problem)?

You are a little sparse on details. In order to be able to help you we
need some more information. Minima are, how are you running this and how
are you doing the deletion? The interactive client has its own memory
settings if you for instance are using that in combination with a
server. Once you have gotten the exception you might be in a
irreversible state, which you only might be able to recover from with a
hard kill of the jvm process.

Cheers,
Leif-Jöran

Gmane