Hi Eric,

You are correct, you can only execute a main module.  If you want to
execute a function in a library module, you have to call that function
from a main module.

Note that you can also create functions in a main module, but those
functions are only available to that main module.

This is an XQuery thing, not just an XCC thing.

-Danny

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Eric
Palmitesta
Sent: Wednesday, November 19, 2008 4:58 PM
To: ML Developer Mailing List
Subject: [MarkLogic Dev General] Can XCC make use of library modules?

Hi all,

I have a question regarding the capabilities of XCC.  Looking at the 
Java code of the ModuleRunner example in the XCC dev guide 
(http://developer.marklogic.com/pubs/4.0/books/xcc.pdf), we're creating 
a ModuleInvoke object, setting the uri of the module on the server we 
want to execute (in the example, the command line argument given is 
"hello.xqy"), and submitting that request to the session.

Sounds like hello.xqy is a main module, rather than a library module, 
although it's unspecified in the documentation (as far as I can see).

Is there a way to execute a particular function in a library module?  If

not, is the workaround to create a wrapper main module for each function

in a library module?

Much thanks,

Eric
_______________________________________________
General mailing list
[email protected]
http://xqzone.com/mailman/listinfo/general
_______________________________________________
General mailing list
[email protected]
http://xqzone.com/mailman/listinfo/general

Reply via email to