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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Hi All, We are writing a simple

Status
Not open for further replies.

Mahi447

Programmer
Jan 12, 2018
16
US
Hi All,

We are writing a simple java program to connect livelink API and get all the ObjecID details (Parent Folder, child folder, sub-child folder...till the doc)

I need to extract data from livelink using java LAPI program.
Is there any function available in livelink API which can fetch attributes value of all the documents resides in Livelink.
--Connect to livelink using LAPI --- then get all the document ObjectId
 
You are the same guy in OT I advised. Search for lapi samples in KB I used to write the Dr Lapi posts in greggriffiths.org
the lapi data structures are pretty complicated when you start but they are rather easy suggest you do your homework based on what all of us are telling you
I also can share old lapi code in java or C# I have written through a google docs link however none of us will be able to hand hold you to write the exact code you want


Here is some info




LLValue catIDList = new LLValue();
LLValue objectInfo = new LLValue();
int getObjectCat;
getObjectCat=doc.ListObjectCategoryIDs(objectID,catIDList);


if getObjectCat == 0
{
//the call worked otherwise we may have to exit
//what if the good value is not a list as we think it is
if catIDList.type() == LLValue.LL_LIST
{
//then we can rest assured we got things we are looking for
//We just parse the list
for(int i = 0; i < catIDList.size(); i++) {
int getObjectInfo;
getObjectInfo=doc.GetObjectInfo(volumeID, catIDList.toValue(i),objectInfo);
if(getObjectInfo==0)
{
System.out.println("********Category related Information********");
System.out.println("Name of the Document "+objectInfo.toString("Name"));
System.out.println("Object ID of the Document "+objectInfo.toInteger("ID"));
System.out.println("Parent ID of the Document"+objectInfo.toInteger("ParentID"));
System.out.println("This version's of the Document created at "+objectInfo.toDate("CreateDate"));
}

}

}


}








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
 
 
HI appnair, thanks for the reply as you said i did some home work & was able to pull the child object but not sub-child,sub-child documents , how i can achieve this ?? (to get the list of all documents including sub children documents)... and is there any way we can traverse across the Parent object and fetch the objectid's on time stamps?????
 
everything in LL is possible through Search Queries, Node list manipulation etc.
If you have a big Object where you need know its dataid
you can say listObjects it will give you the first level,if you now recurse the call you get its objects
or if you are oracle use a connect by query if SQL use a CTE
All LL organizations have either resorted to oracle specific or sql specific
to find the nodes and its children.the dataid of the nod is your lapi handle.
Everything in LL has been driven to death over the years :)
did you not see my first lapi project in Greg Griffiths where I used JDBC no none of those drivers exist now
my task was to retire an entire livelink to file system with file content ,you can see how I traverse
just for the ideas (done somewhere in 2004)
if your dtreeancestors are correct then that query has all the children underneath it
BTW it will take exactly 10 minutes of an administrators time to enable websvcs on a livelink server...

Try creating a LL project(subtype 202) and add one or two folders to it and use the overview page ,do you see a indented representation
of all the objects underneath it.If that works just change the dataid to a not deeply nested folder object it should show you the
child items as well.This is what LL code doe it tries to find things based on a starting location.

You can even screen scrape the dataid's to a poor solution...

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
 
Thanks appnair for reply, i was able to perform the search across the container and able to bring the result set.Now i am looking to do search between time stamps (start date, end date) .... how can where clause can be define???
 
appnair, search XML API is separate API from LAPI ??? is there anyway we can construct the WHERE class with AND/OR operator will this works ???

AS to get the list of child documents, i wrote a recursive method which will produce the child & subchild documents IDS rather then using Oracle/Sql configurations.

Now my goal is to get the doc with in the time range.
 
Thanks appnair for the reply, i wrote a simple java code with LAPI & did a search against the Modify date using the '>' operator which gave me the results, but i wonder how we can use SQL queries "Select DataID,Name,SubType form DTree where CreateDate (or ModifyDate) between and then the time stamps" in LAPI Using java..
 
Thanks appnair. i am looking to do a search on particular ObjectId or Parent ID to get the child doc with in the specific date range...

The links which you gave me doesnt provide much info what i am looking for .
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top