Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

LAPI 9.7.1 error

Status
Not open for further replies.

kg7

Programmer
Sep 10, 2014
1
IN
Hi,

I am using LAPI 9.7.1 api for accessing OpenText Content Server 10.

I want to fetch the categories present in Enterprise worksapce and using below mentioned code for it -

LLValue mWorkspaceInfo = (new LLValue()).setAssocNotSet();
int iVolumeID = mWorkspaceInfo.toInteger("VolumeID");
int iobjID = mWorkspaceInfo.toInteger("ID");

LLValue children = (new LLValue()).setTable();
mLogger.Debug("Fetching all categories from the workspace");

if (mDocuments.ListObjects(iVolumeID, iobjID, "DTREE", "SUBTYPE = " + LAPI_DOCUMENTS.CATEGORYSUBTYPE, LAPI_DOCUMENTS.PERM_FULL, children) != 0)
{
Exception e = new Exception("CONNECTIONNOTOPEN");
throw e;
}

It is giving me this exception - com.opentext.api.LLIllegalOperationException “toInteger() not implemented for this datatype”

But when I replace DTREE parameter with null , it works fine.

Can anyone help me please.

Thanks






 
do you have access to livelink or a sql tool so the lapi command you ran is akin to

select * from dtree where subtype=131
the ownerid column is the volumeid in your code dataid for each category object
usually the volumeid can be ignored but usually category's volumedid id is not the
enterprises volume id.

if the call works like this
if (mDocuments.ListObjects(iVolumeID, iobjID, "DTREE", "SUBTYPE = " + LAPI_DOCUMENTS.DOCUMENTSUBTYPE, LAPI_DOCUMENTS.PERM_FULL, children) != 0)
then it is probably the volumeid that is wrong
the above call is akin to select * from dtree where subtype=144

make sure each lapi call is evaluated to a zero for success and you should parse return data structures only on success.If it is not a success you will get errors like this
com.opentext.api.LLIllegalOperationException “toInteger() not implemented for this datatype”


get some smaple lapi code form site like or opentext.com and do run some simple lapi stuff so you get the feel of it



Well, if I called the wrong number, why did you answer the phone?
James Thurber, New Yorker cartoon caption, June 5, 1937
Certified OT Developer,Livelink ECM Champion 2008,Livelink ECM Champion 2010
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top