1. Get rid of all advertisements and get unlimited access to documents by upgrading to Premium Membership. Upgrade to Premium Now and also get a Premium Badge!

unable to checkin a document using 'CHECKIN_UNIVERSAL" service through java

Discussion in 'Oracle Webcenter Suite (formerly Oracle ECM)' started by poornimabalagopal, Jun 6, 2011.

  1. poornimabalagopal

    poornimabalagopal Active Member

    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    55
    Hi
    I am trying to checkin a file to UCM (UCM 11g) through java code.But its throwing an error "intradoc.common.ServiceException:csUnableToCheckin,<null>!csUnabletoExecMethod,populateMissingDocumentValues"

    Does anyone know what could be the problem ?



    My code part is as given below
    public boolean uploadFilesToUCM(final String[] metadata,DataBinder eventData,Workspace workspace)
    {
    boolean result = false;
    try
    {
    File f=new File("D:/testfolder/Oracle IPM - Admin.doc");
    System.out.println(" absolute path :"+f.getAbsolutePath());
    System.out.println(eventData.getLocal("m_userData"));

    String filePath = eventData.getTemporaryDirectory().replace("\\", "/");
    System.out.println(" doc title :"+metadata[2]);
    eventData.putLocal("IdcService", "CHECKIN_UNIVERSAL");
    eventData.putLocal("dDocTitle", "test");
    eventData.putLocal("dDocAuthor", "weblogic");
    eventData.putLocal("dDocType", "Document");
    eventData.putLocal("dSecurityGroup", "public");
    eventData.putLocal("xCollectionID", "425180507509000004");
    // eventData.putLocal("primaryFile:path", filePath);
    eventData.putLocal("primaryFile", filePath);
    eventData.putLocal("doFileCopy", "1");


    ServiceData servicedata = ServiceManager.getService("CHECKIN_UNIVERSAL");
    Service service1 = ServiceManager.createService(servicedata.m_classID,
    workspace, null, eventData, servicedata);
    service1.setSendFlags(true, true);
    service1.initDelegatedObjects();
    service1.setUserData(m_userData);
    service1.globalSecurityCheck();
    service1.preActions();
    service1.doActions();
    service1.postActions();
    result = true;
    }
    catch(Exception e)
    {
    System.out.println(" error in checking in the file");
    e.printStackTrace();
    }
    return result;


    }


    but when i run this code, it shows an error as given below
    intradoc.common.ServiceException:csUnableToCheckin,<null>!csUnabletoExecMethod,populateMissingDocumentValues

    I have disabled ZipRenditionComponent.

    Regards,
    Poornima
     
  2. dcell59

    dcell59 Forum Advisor

    Messages:
    103
    Likes Received:
    18
    Trophy Points:
    260
    I don't see a content ID (dDocName). Is that being auto-generated? Does the server audit information tell you what other values might be missing?

    One thing to try is setting "isNew" to "1". Another is that if you have Workflow, you may need to set "isCheckin" to "1".
     
  3. poornimabalagopal

    poornimabalagopal Active Member

    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    55
    Hi,
    First of all thanks for the reply.
    Yes My dDocName is automated and there is no workflow.

    There is one clue which I found after a lot of googling around is - if i set xCollectionID for checkin_universal, it fails but it does work well with RIDC.

    so may be when i use xCollectionID in the normal way, it might be expecting some other parameters to be set - which i am not sure what they could be!!!!!!
     
  4. dcell59

    dcell59 Forum Advisor

    Messages:
    103
    Likes Received:
    18
    Trophy Points:
    260
    Try setting "hasCollectionID" to "true".

    BTW, if you can find someone with RIDC who can do a working checkin, ask them to get you a Fiddler trace of a successful checkin. That will help you see what parameters are being sent.
     
  5. dcell59

    dcell59 Forum Advisor

    Messages:
    103
    Likes Received:
    18
    Trophy Points:
    260
    Oh, and once again, you should take a look at the server audit information. It may tell you what parameter is missing.