I Recently Upgraded from MarkLogic-8 to MarkLogic-9, and i am having following set of Documents in MarkLogic-8,
Collection - System, User
Document URI - /user.xml
Collection - System, Role
Document URI - /role.xml
Collection - System, Admin
Document URI - 1. /systemadmin.xml
2. /accountadmin.xml
Following is Sample java code snippet that i am using to retrieve all the documents from collections
String[] collections = {"System", "Admin"};
QueryManager queryMgr = client.newQueryManager();
SearchHandle resultsHandle = new SearchHandle();
StringQueryDefinition query = queryMgr.newStringDefinition();
query.setCollections(collections);
queryMgr.setPageLength(Long.parseLong(UIParam.PAGINATION_PAGE_LENGTH));
queryMgr.search(query, resultsHandle);
When I execute above java code snippet on MarkLogic-8, i got /systemadmin.xml and accountadmin.xml as result and this is correct result,
but now when i am executing above code against MarkLogic-9 i am getting all the documents /user.xml, /role.xml, /systemadmin.xml, /accountadmin.xml and this is wrong result.
<dependency>
<groupId>com.marklogic</groupId>
<artifactId>marklogic-client-api</artifactId>
<version>4.1.0</version>
</dependency>
Maven dependency for MarkLogic-9
I am confused that why there is difference between MarkLogic-8 and MarkLogic-9 result.
Please help me to Resolve this issue.