Geert, The version of Marklogic is 4.2-3.2

Best Regards,
Kashif Khan
Sr. Solutions Architect
Houghton Mifflin Harcourt, Orlando, FL
Office: (407) 345-3420
Cell: (407) 949-4697

"The water you touch in the river is the last of that which has passed and the 
first of that which is coming" --Leonardo da Vinci



From: Geert Josten <geert.jos...@dayon.nl<mailto:geert.jos...@dayon.nl>>
Reply-To: General MarkLogic Developer Discussion 
<general@developer.marklogic.com<mailto:general@developer.marklogic.com>>
Date: Wed, 25 Jan 2012 02:15:35 -0500
To: General MarkLogic Developer Discussion 
<general@developer.marklogic.com<mailto:general@developer.marklogic.com>>
Subject: Re: [MarkLogic Dev General] searchable-expression

Hi Kashif,

Which version of MarkLogic are you running? Your code seems to run just fine in 
5.0-2.

Kind regards,
Geert

Van: 
general-boun...@developer.marklogic.com<mailto:general-boun...@developer.marklogic.com>
 
[mailto:general-boun...@developer.marklogic.com<mailto:general-boun...@developer.marklogic.com>]
 Namens Khan, Kashif
Verzonden: dinsdag 24 januari 2012 23:30
Aan: General MarkLogic Developer Discussion
Onderwerp: [MarkLogic Dev General] searchable-expression

I am getting an error when I try to run the following query. Any help will be 
appreciated to resolve this issue.

search:search('Title:(power) Show:productsets special:title',
    <options  xmlns="http://marklogic.com/appservices/search";>


<operator name="special">
   <state name="title">

       <searchable-expression xmlns:pce="http://pcenamespace";
                
xmlns:dc="http://purl.org/dc/elements/1.1/";>/pce:productSet/dc:title

      </searchable-expression>

   </state>
</operator>

   </options>
)


Error:

query evaluated in pce at pce-modules:/ as 1.0-ml (cq v4.0-1.1)

[1.0-ml] XDMP-ARGTYPE: (err:XPTY0004) 
fn:in-scope-prefixes((<searchable-expression 
xmlns:dc="http://purl.org/dc/elements/1.1/"; xmlns:pce="http://pcenamespace"; 
xmlns="http://marklogic.com/appservices/search";>/pce:productSet/dc:title&#10; 
&#10; </searchable-expression>, <searchable-expression 
xmlns:dc="http://purl.org/dc/elements/1.1/"; xmlns:pce="http://pcenamespace"; 
xmlns="http://marklogic.com/appservices/search";>/pce:productSet/dc:title&#10; 
&#10; </searchable-expression>)) -- arg1 is not of type element()

Stack trace:
in /MarkLogic/appservices/search/search-impl.xqy line 2047:
impl:build-ns-bindings(<options 
xmlns="http://marklogic.com/appservices/search";><searchable-expression 
xmlns:dc="http://purl.org/dc/elements/1.1...</options>)

$options := <options 
xmlns=<http://purl.org/dc/elements/1.1...%3c/options%3e)%0b%0b$options%20:=%20%3coptions%20xmlns=>"http://marklogic.com/appservices/search";><searchable-expression
 xmlns:dc="http://purl.org/dc/elements/1.1...</options>
$map := map:map()
$opt-ns := ()
in /MarkLogic/appservices/search/search-impl.xqy line 1354:
impl:build-order-by(<options 
xmlns="http://marklogic.com/appservices/search";><searchable-expression 
xmlns:dc="http://purl.org/dc/elements/1.1...</options>)

$options := <options 
xmlns=<http://purl.org/dc/elements/1.1...%3c/options%3e)%0b%0b$options%20:=%20%3coptions%20xmlns=>"http://marklogic.com/appservices/search";><searchable-expression
 xmlns:dc="http://purl.org/dc/elements/1.1...</options>
in /MarkLogic/appservices/search/search-impl.xqy line 1339:
impl:build-flwor(<options 
xmlns="http://marklogic.com/appservices/search";><searchable-expression 
xmlns:dc="http://purl.org/dc/elements/1.1...</options>, <cts:and-query 
strength=<http://purl.org/dc/elements/1.1...%3c/options%3e,%20%3ccts:and-query%20strength=>"20"
 qtextjoin="" xmlns:cts="http://marklogic.com/cts";><cts:word-query 
qtextref="cts:text"><cts:text>Title:power</cts:t...</cts:and-query>, 
xs:unsignedLong("1"), 10, <quality-weight 
xmlns="http://marklogic.com/appservices/search";>1.0</quality-weight>, ())

$options := <options 
xmlns="http://marklogic.com/appservices/search";><searchable-expression 
xmlns:dc="http://purl.org/dc/elements/1.1...</options>
$cts := <cts:and-query 
strength=<http://purl.org/dc/elements/1.1...%3c/options%3e%0b$cts%20:=%20%3ccts:and-query%20strength=>"20"
 qtextjoin="" xmlns:cts="http://marklogic.com/cts";><cts:word-query 
qtextref="cts:text"><cts:text>Title:power</cts:t...</cts:and-query>
$start := xs:unsignedLong("1")
$end := 10
$quality-weight := xs:double("1")
$forests := ()
$scope := <searchable-expression xmlns:dc="http://purl.org/dc/elements/1.1/"; 
xmlns:pce="http://pcenamespace"; 
xmlns="http://marklogic.com/appservices/search";>/pce:productSet/dc:title&#10; 
&#10; </searchable-expression>
in /MarkLogic/appservices/search/search-impl.xqy line 1189:
impl:do-query("Title:(power) Show:productsets special:title", <options 
xmlns="http://marklogic.com/appservices/search";><operator name="special"><state 
name="title"><searchable-express...</options>, (), 1, (), fn:false())

$qtext := "Title:(power) Show:productsets special:title"
$deltaoptions := <options 
xmlns="http://marklogic.com/appservices/search";><operator name="special"><state 
name="title"><searchable-express...</options>
$ctsquery := ()
$start := xs:unsignedLong("1")
$page-length := ()
$raw-results := fn:false()
$t-minus-0 := xs:dayTimeDuration("PT0.001371S")
$init-options := <options 
xmlns="http://marklogic.com/appservices/search";><operator name="special"><state 
name="title"><searchable-express...</options>
$parsed-query := <cts:and-query strength="20" qtextjoin="" 
xmlns:cts="http://marklogic.com/cts";><cts:word-query 
qtextref="cts:text"><cts:text>Title:power</cts:t...</cts:and-query>
$options := <options 
xmlns="http://marklogic.com/appservices/search";><searchable-expression 
xmlns:dc="http://purl.org/dc/elements/1.1...</options>
$return-results := fn:true()
$return-metrics := fn:true()
$return-facets := fn:true()
$return-plan := ()
$return-qtext := fn:true()
$return-query := fn:false()
$return-constraints := fn:false()
$return-similar := fn:false()
$format-fname := 
attribute{fn:QName(<http://purl.org/dc/elements/1.1...%3c/options%3e%0b$return-results%20:=%20fn:true()%0b$return-metrics%20:=%20fn:true()%0b$return-facets%20:=%20fn:true()%0b$return-plan%20:=%20()%0b$return-qtext%20:=%20fn:true()%0b$return-query%20:=%20fn:false()%0b$return-constraints%20:=%20fn:false()%0b$return-similar%20:=%20fn:false()%0b$format-fname%20:=%20attribute%7bfn:QName(>"",
 "apply")}{"snippet"}
$extra-cts := ()
$quality-weight := <quality-weight 
xmlns="http://marklogic.com/appservices/search";>1.0</quality-weight>
$forests := ()
$page-length := 10
$page-length := 10
$debug-mode := fn:false()
$options-validate := ()
$start := xs:unsignedLong("1")
$start := xs:unsignedLong("1")
$end := 10
$log := ()
$combined-query := <cts:and-query strength="20" qtextjoin="" 
xmlns:cts="http://marklogic.com/cts";><cts:word-query 
qtextref="cts:text"><cts:text>Title:power</cts:t...</cts:and-query>
$warnings := ()
in /MarkLogic/appservices/search/search.xqy line 31:
search:search("Title:(power) Show:productsets special:title", <options 
xmlns="http://marklogic.com/appservices/search";><operator name="special"><state 
name="title"><searchable-express...</options>)

$qtext := "Title:(power) Show:productsets special:title"
$options := <options xmlns="http://marklogic.com/appservices/search";><operator 
name="special"><state name="title"><searchable-express...</options>
line 49:
47: :)
48:
49: search:search('Title:(power) Show:productsets special:title',
50: <options xmlns="http://marklogic.com/appservices/search";>
51:

xdmp:eval("xquery version &quot;1.0-ml&quot;;&#13;&#10;declare namespace 
pc...", (), <options 
xmlns="xdmp:eval"><database>4505916305078430272</database><modules>342058231065734...</options>)

in /eval.xqy line 93:


Best Regards,
Kashif Khan
Sr. Solutions Architect
Houghton Mifflin Harcourt, Orlando, FL
Office: (407) 345-3420
Cell: (407) 949-4697

"The water you touch in the river is the last of that which has passed and the 
first of that which is coming" --Leonardo da Vinci
_______________________________________________
General mailing list
General@developer.marklogic.com
http://developer.marklogic.com/mailman/listinfo/general

Reply via email to