I'm working on a Java project which is connected to documentum . I am trying to fetch some data from my dm_acl object table using the following :
String fetchAclsInfoQuery = "select * from dm_acl where description = '@aclname0' or description = '@aclname1' or description = '@aclname2' enable (ROW_BASED) ";
fetchAclsInfoQuery = fetchAclsInfoQuery.replace("@aclname0", list.get(0));
fetchAclsInfoQuery = fetchAclsInfoQuery.replace("@aclname1", newAcl1.toString().toLowerCase());
fetchAclsInfoQuery = fetchAclsInfoQuery.replace("@aclname2", newAcl2.toString().toLowerCase());
System.out.println(fetchAclsInfoQuery);
//The problem starts from here ==>
IDfQuery aclDetailsFetching = new DfQuery();
//IDfCollection col = UpdateQuery.execute(_session, IDfQuery.DF_QUERY);
IDfCollection details = aclDetailsFetching.execute(_session, DfQuery.DF_READ_QUERY);
while(details.next()){
System.out.println(details.getString("owner_name"));
}
once I print out the results of "fetchAclsInfoQuery" and run it in DQL tester it works perfectly fine how ever when I try to out put the values stored in "owner_name" column all I get is null . Any idea where my mistake is ? :)
You forgot to set DQL statement to query object.
add aclDetailsFetching.setDQL(fetchAclsInfoQuery);