atom feed10 messages in com.marklogic.developer.generalRe: [MarkLogic Dev General] New serve...
FromSent OnAttachments
Anshu RahejaJan 25, 2012 4:26 am 
Geert JostenJan 25, 2012 4:45 am 
Anshu RahejaJan 25, 2012 4:52 am 
Anshu RahejaJan 26, 2012 3:10 am 
Geert JostenJan 26, 2012 6:29 am 
Dean PullenJan 30, 2012 9:24 am 
Dean PullenFeb 1, 2012 4:07 am 
Dean PullenFeb 1, 2012 4:46 am 
Geert JostenFeb 1, 2012 5:23 am 
Dean PullenFeb 1, 2012 5:25 am 
Subject:Re: [MarkLogic Dev General] New server not finding namespaces
From:Anshu Raheja (Ansh@semantico.com)
Date:Jan 26, 2012 3:10:11 am
List:com.marklogic.developer.general

Hi Greet,

Is there any way to resolve the local prefix problem.

Thanks, Anshu

Thanks for the response.

We are using it in the main module and xquery version has been declared as 'xquery version "1.0-ml";'.

Regards, Anshu

On 25/01/2012 12:45, Geert Josten wrote:

Hi Anshu,

It is correct that you need to declare namespaces in your XQuery to address Range indexes that use them. It is because indexes work with qualified names (QNames), so you need both a namespace (uri or prefix bound to uri) and a local name to be able to address the right QName from you query, and select the appropriate index that way. Adding a namespace uri to an index does not automatically make it known within XQuery code..

About the local namespace prefix. Where are you using it (main module or library module), and what is the xquery version that you declared on top? 1.0-ml?

Kind regards, Geert

-----Oorspronkelijk bericht----- Van: gene@developer.marklogic.com [mailto:gene@developer.marklogic.com] Namens Anshu Raheja Verzonden: woensdag 25 januari 2012 13:28 Aan: General MarkLogic Developer Discussion CC: Dean Pullen Onderwerp: [MarkLogic Dev General] New server not finding namespaces

Hi all,

New to Marklogic and setting up a new dev server (4.2-8), existing server is 4.2-4, and finding that our current Xquery scripts aren't working on the new server setup.

It seems the namespaces setup in the database Element Range Indexes etc aren't found (we have to add the namespace manually to each Xquery file), AND that 'local:' is not recognized, e.g.

com.marklogic.xcc.exceptions.XQueryException: XDMP-NONAMESPACEBIND: (err:FONS0004) local:asis($node) -- No namespace binding for prefix on line 38 expr: local:asis($node), in local:asis(fn:doc("/content/10.1007/s00464-009-0856-x")/item/*:issn[1])

Can anyone help? Thanks in advance.

Anshu