COGNOiSe.com - The IBM Cognos Community

IBM Cognos 10 Platform => Cognos 10 BI => SDK => Topic started by: fulekia on 15 Oct 2014 11:29:09 AM

Title: SearchPathMultipleObject weirdness
Post by: fulekia on 15 Oct 2014 11:29:09 AM
I'm using the 10.2.1 Java SDK to query our content store for all report, query, and reportView objects, and getting different, incomplete results when using different searchPaths.

Broad searches (e.g., "//report | //query | //reportView", or "//*[@objectClass='query' or @objectClass='report' or @objectClass='reportView']") are incomplete, missing a lot of objects in their results.

More specific searches that include a path fragment (e.g., "/content/folder[@name='Test']//*[@objectClass='query' or @objectClass='report' or @objectClass='reportView']"), successfully return all of the objects at or below said path.

I can find no pattern as to which objects drop out of the results or why. Sometimes certain objects from the same subfolder do/don't come back, so the search clearly recursed to said path (I get 3 of the 6 reports in a folder, no difference in privs). I'm using the same credentials each time, and that user has the necessary privs (it can see all objects in Cognos Connection, all objects are returned by more specific queries). I've re-read the searchPath section of the SDK manual about a hundred times at this point. My current workaround is one query to return all of the top-level folders, then iterate over that with more specific queries to get their objects, then mash those results together. That seems unnecessary.

Has anyone seen this before? I'm inclined to think this is a bug, based on threads I've found on COGNOISe and elsewhere, but thought it was worth a shot asking around before opening a ticket with IBM.