Hello everyone,
I am able to fetch list of object name and data id using ListObjects, This works if the folder has about 35000 objects.
But i have 70000 objects under a folder. My LAPI code struck and not giving any results.
Can anybody got such kind of issue. Any workaround please.
Below is my code
import com.opentext.api.LAPI_DOCUMENTS;
import com.opentext.api.LLNameEnumeration;
import com.opentext.api.LLSession;
import com.opentext.api.LLValue;
public class ObjID {
// public static final int MAX_SIZE = 100;
public static void main (String argv[]) {
try {
//Create a new Livelink Session
LLSession session;
session = new LLSession ("xx.com", 5000,"", "Admin", "Admin", null);
int objID = 34211244;
int volID = 0;
String viewName = null;
String queryStr= null;
LAPI_DOCUMENTS doc = new LAPI_DOCUMENTS(session);
LLValue children = new LLValue().setAssoc();
LLValue childrenNumber = new LLValue().setAssoc();
if (doc.ListObjects(volID, objID, viewName,queryStr , 0, children) == 0)
{
for (int i = 0; i < children.toValue("NAME").size(); i++)
{
System.out.println(children.toValue("NAME").toValue(i) + "|" + children.toValue("ID").toValue(i) );
}
}
}
catch (Throwable e) {
System.err.println(e.getMessage());
e.printStackTrace(System.err);
}
}
}
I am able to fetch list of object name and data id using ListObjects, This works if the folder has about 35000 objects.
But i have 70000 objects under a folder. My LAPI code struck and not giving any results.
Can anybody got such kind of issue. Any workaround please.
Below is my code
import com.opentext.api.LAPI_DOCUMENTS;
import com.opentext.api.LLNameEnumeration;
import com.opentext.api.LLSession;
import com.opentext.api.LLValue;
public class ObjID {
// public static final int MAX_SIZE = 100;
public static void main (String argv[]) {
try {
//Create a new Livelink Session
LLSession session;
session = new LLSession ("xx.com", 5000,"", "Admin", "Admin", null);
int objID = 34211244;
int volID = 0;
String viewName = null;
String queryStr= null;
LAPI_DOCUMENTS doc = new LAPI_DOCUMENTS(session);
LLValue children = new LLValue().setAssoc();
LLValue childrenNumber = new LLValue().setAssoc();
if (doc.ListObjects(volID, objID, viewName,queryStr , 0, children) == 0)
{
for (int i = 0; i < children.toValue("NAME").size(); i++)
{
System.out.println(children.toValue("NAME").toValue(i) + "|" + children.toValue("ID").toValue(i) );
}
}
}
catch (Throwable e) {
System.err.println(e.getMessage());
e.printStackTrace(System.err);
}
}
}