Questions tagged [marklogic-10]

Indicates questions specific to MarkLogic 10; use with the [MarkLogic] tag but not in place of.

MarkLogic 10 is the latest release of MarkLogic's NoSQL document database.

198 questions
2
votes
1 answer

Fail to initialize ml gradle project (mlDeployApp) with the rest-api-server

Fail to deploy a brand new mlgradle project to Marklogic 10.0-9.2-centos-1.0.0-ea4 in docker desktop. Execution failed for task ':mlDeployApp'. > java.net.ConnectException: Failed to connect to localhost/127.0.0.1:8900 Steps to replicate the…
2
votes
2 answers

In XQuery Marklogic how to sort dynamically?

In XQuery Marklogic how to sort dynamically? let $sortelement := 'Salary' for $doc in collection('employee') order by $doc/$sortelement return $doc PS: Sorting will change based on user input, like data, name in place of salary.
anuj_gupta
  • 131
  • 4
2
votes
1 answer

MarkLogic database deleted on deleting the field range index

There is a bug in ML v10.0-4.2. When we create a field range index through admin API and delete it through admin UI, the database configuration gets deleted and the database becomes inaccessible. This bug has been documented by MarkLogic (BUG-54775)…
2
votes
0 answers

fn.subsequence work different in optic API

In my program I need to join 2 and more collections by some json properties. When I run only subsequence method it return array of json objects but when I use it in op.fromLiterals in my optic plan it returns a list of document uris. I can't use the…
2
votes
1 answer

Marklogic - Optic API: Joining views by value (op:on does not support values, only column-references)

I'm trying to join two views "A" and "B" using the op:join-left-outer function. I have two "ON-conditions" for the JOIN: The first one is a simple op:on function. (And not a part of my problem) The second one should be an ON-condition joining a…
GoatyGuy
  • 133
  • 1
  • 8
2
votes
2 answers

CORB: Undefined external variable fn:QName("","URI")

I am new to CORB, Trying to delete documents using Java code but I am getting com.marklogic.xcc.exceptions.XQueryException: XDMP-EXTVAR: (err:XPDY0002) declare variable $URI as xs:string* external; -- Undefined external variable fn:QName("","URI")…
DevNinja
  • 1,459
  • 7
  • 10
2
votes
1 answer

Marklogic Scaling down in EC2 using cloud formation Template

Currently i am using the Marklogic cloud formation template (https://marklogic-db-template-releases.s3-us-west-2.amazonaws.com/10.0-latest/mlcluster-vpc.template) given by Marklogic itself and launched a cluster (3 nodes in 1 zone) and later I was…
Vikram
  • 635
  • 1
  • 9
  • 29
2
votes
1 answer

Optic API vs CTS query performance

I am using below two queries(Optic and CTS) to get the values for path-range index /tXML/Item/PutawayCategory. Query 1: - It took approx. 4 milliseconds to execute and return 17 distinct values. I tried executing this same query multiple…
DevNinja
  • 1,459
  • 7
  • 10
2
votes
1 answer

Call java function using XQuery in MarkLogic

Is it possible to call java function using XQuery in MarkLogic. ? Please refer - https://stackoverflow.com/questions/65953901/calling-java-method-from-xquery Example - declare namespace math="java:java.lang.Math"; math:sqrt(2)
DevNinja
  • 1,459
  • 7
  • 10
2
votes
1 answer

Convert timestamp to dateTime in MarkLogic

I am using xdmp:document-timestamp function to get the timestamp of the most recent update that happened on this document. Above function returns timestamp as output like: 16222984921692864. How can I convert this timestamp 16222984921692864 to the…
DevNinja
  • 1,459
  • 7
  • 10
2
votes
0 answers

Marklogic entity property versus relationship for an effective Mastering

I have a question around best practices in the design of entities in MarkLogic. When we design a property under an entity, it can have classic types or also other entity types. Example: Entity A |-id (string) |-property1 (string) |-property2…
Rad
  • 989
  • 3
  • 14
  • 31
2
votes
1 answer

cts.estimate showing wrong document count

My requirement is get the count of total documents available in database. cts.estimate( cts.trueQuery() ) When I execute above query it is returning 1283265 document count but when I explore database from qconsole then document count is 1283262…
DevNinja
  • 1,459
  • 7
  • 10
2
votes
2 answers

Read documents in order

We have a list of URIs and which we need to read in the sequence in which it is passed. Example1 doc(("/doc1", "/doc2", "/doc3")) above function should return the content of "/doc1" then "/doc2" and then "/doc3" but it is not happening. The same…
DevNinja
  • 1,459
  • 7
  • 10
2
votes
1 answer

SVC-CODEPOINT error loading triples to MarkLogic

When trying to load an ntriples file with about 7M triples in it, I get the following error from the REST-API: {"errorResponse":{"statusCode":500, "status":"Internal Server Error", "messageCode":"INTERNAL ERROR", "message":"SVC-CODEPOINT:…
kefo
  • 43
  • 4
2
votes
1 answer

MarkLogic unit test not running any tests

I thought it would be a good idea to set up MarkLogic unit testing, so I've been following the unit-test-project as best as I can. Everything seems to work, but no unit tests are being performed. I've copied the four unit tests to…
eaolson
  • 14,717
  • 7
  • 43
  • 58
1
2
3
13 14