Entity Services test in service browser

Hello,
The problem that I'm encountering is a quite strange one (as all problems, before being solved:)). I have a rather complex structure of Entity Services that relate between each other. All built and deployed on the J2EE Server. No errors, no warnings. Then I wanted to insert some new entries in the tables, so I navigated to the service in the service browser and in the newly opened WebDynpro interface clicked on New. All fine so far, but the table, in which i want to insert, has a relation to another table, which already have some values inserted. The related table has also a number of custom defined operations like FindById. For unknown reason however, I can see only the action readByCustomKeys in the related table and thus I can't select the key to which my new entry has to be related. The workaround is of course to go to the other table and copy the key of the field to which I want to relate. So to sum up, can someone tell me first why I see only the readByCustomKeys action in the related Actions dropdown and second why even after using this action and typing an existing CustomKey I don't get any results back. What I noticed is that if I type a wrong CustomKey (non existing) I get an error that looks like this:
ERROR. Incorrect query result size for ObjectClass class <classname>
A quick tip is highly appreciated and of course with points rewarded:)
Greetings,
Todor

Hi,
Is it possible to tell me the details what you have done or you can send me the project in my mail address [email protected] I will try it and gibe you the reply.
Thanks
Chandan

Similar Messages

  • Error while testing the created entity service

    Hi
    I have an error  "access forbidden.please login again" while testing the entity service  in the service browser.Please help.
    Regards
    ms.

    Hi,
    I think this is not a problem from your end.  You please check for another entity service. If you get the same error then this is the problem from server side. If possible please restart the server and try it again.
    Thanks
    Chandan

  • Error while testing entity service

    Hi all,
                I created a CAF Development component and an entity service for the same. While trying test the entity service through service browser i get the follwing error :
    Application error occurred during request processing.
    Details:com.sap.tc.webdynpro.services.exceptions.WDRuntimeException: Failed to create deployable object 'sap.com/cafUIservicebrowser' since it is not of a Web Dynpro object.
    Exception id: [0014225F392C006100000013000009A400042388306C40DD]
    Please help...
    Regards,
    Sharmila
    Message was edited by:
            Sharmila S

    Hi Sharmila,
    It looks like your WAS does not have CAF deployed.
    Regards,
    Shubham

  • Error When Testing Entity Services

    Hi!
    I have recently installed NW04s, and when I develop Entity Services the deploy without any problems. I can also open them in the Service Browser without any problem.
    However, when I try to create records in the database I get the following error:
    ERROR. Exception thrown in method create. The transaction is marked for rollback.: com/sap/caf/rt/exception/CAFIllegalAccessException
    Does anybody knows how to solve this problem?
    I use local persistency wothout any permission checks.
    i am also facing same problem with EP7.0 combination with NWDS7.0.07Version.
    Regards,
    Amit.
    Message was edited by:
            Amit Bakshi

    Hi Amit
    It seems there is a luck of information to resolve your problem. Please, go to Visual Admin -> Log Viewer service and check log messages with Warning or Error severities. Post them here and it will help to resolve your error.
    BR
    Sergei

  • UnAuthorized Exception while testing Entity Service

    Hi, I have created a plain java class method as webservice.While creating the webservice from the IDE i have selected Default Configuration type as Basic Auth SOAP.I am using this webservice as external service in CAS project.But when i tested this entity service i am getting the Unuthorized exception.This is not the case when i am creating the webservice with configuration Simple SOAP.Kindly help me on this regard.

    Hi Sudhir,
    While configuring the external service in service registry,select the basic authenitication option and set the user id and password.
    Hope this will work.
    Sampath.G

  • Entity Services: readByCustomKeys operation mapped to External Service

    Hello *,
    in my CAF application I'd like to read a product from SAP PLM. Within my Entity Service materialNumber is my custom key and therefore a corresponding operation exists: readByCustomKeys.
    I map this operation to my External Service (Web service provided by XI).
    As I can't test this operation directly with the Service Browser (deosn't appear there), I wrap  my Entity Service with an Application Service where I use the readByCustomKeys operation from Entity Service.
    Now when I test the Application Service operation I get the following error message in Service Browser:
    ERROR. Invalid type value :
    In XI I can see that there was no error and I got well defined XML data as response. So the problem must occur anywhere in the mapping back from External Service data to Entity Service attributes.
    Wrong data type mapping can be excluded as I already tested this possibility.
    Does anyone know what could be the reason?
    Thanks for your answers and best regards
    Joschi

    Hello Joachim,
    I dont have a lot of experience with readByCustomKeys (one experience which failed) but uou can also use read itself. If you have defined materialNumber as a key in your entity service, then this field can be used in read operations as well (I have a lot of positve experiences with this approach). You will find materialNumber while mapping read with your external service and you need not map the key field generated by Entity Service.
    For testing entity services, we have had several positive experiences with the config browser, specially for a findBy, read and even update operation. It was very easy to have a prototype UI to check the entity services.
    I know this isnt the answer to your question, but just sharing my experiences.
    All the best!!!
    Regards,
    Parag.

  • CAF DB Update for CAF Entity Service from Web Dynpro

    Hi all,
    I have created an entity service in CAF called “Contacts’ which contains the following attributes.
    phoneNo
    cellNo
    emailID.
    Another entity service called "Person" is created. This contains the following attributes.
    personId
    personName
    personAddr
    contactsRef. (Cardinality -> 0..n , Relational Type -> Composition)
    That means Contacts entity service is used within Person entity service. Now it is working fine within CAF service browser. Now the Web Dynpro DC of CAF application is used within another custom Web Dynpro DC project. I want to store data from Web Dynpro.
    Within the context of component controller of  Web Dynpro the structure is like
    APerson
         |_ personId
         |_ personName
         |_ personAddr
         |_ contactsRef       
                    |_ phoneNo (Under contactsRef)
                    |_ cellNo (Under contactsRef)
                    |_ emailID (Under contactsRef)
    So I have written the following code within web dynpro custom method.
    APerson person = PersonServiceProxy.create();
    java.util.List ls = new ArrayList();
    for(int i=0; i<4;i++)
    AContacts contact = ContactsServiceProxy.create();
    contact.setCellNo("9092130156");
    contact.setEmailID("[email protected]");
    contact.setPhoneNo("432258");
    contact.getAspect().sendChanges();
    ls.add(contact);
    person.setRelatedModelObjects("contactsRef",ls);
    person.setPersonID("9999");
    person.setPersonName("xyz");
    person.setPersonAddr("ABC, KOL");
    wdContext.nodeAPerson().bind(person);
    person.getAspect().sendChanges();
    CAFServiceFactory.getServiceFacade(idendityDefinition.class);
    After saving the data from Web Dynpro I am trying to test it from CAF service browser. But I am getting only the parent row. I mean only the value of personId, personName and personAddr fields which I have stored from Web Dynpro. But no value is coming within the table for Contacts entity service for composition relation.
    Could anybody help me how can I solve my problem?
    Thanks & Regards
    Chandan
    Message was edited by:
            Chandan Jash

    Hi Chandan,
    Can you do person.getRelatedModelObjects() and get the contact object, to check whether it is null, also check in the CAF DB whether the data you entered is present.
      I am not sure the code is actually adding the contact model object to person.
    Go thru this SDN Blog on usage of the CMI API's, there is a link for CMI documentation in it which might help you get the right code for adding the contact object.
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/cef4f43e-0d01-0010-db84-ede25c874115.
    award points if  info is helpful
    Regards,
    Anish

  • Selecting Key for Entity Services in CAF

    Hello All,
    I have a question. While creating attributes for an entity service, we have an option to select it as key or complex. Suppose if we choose many attributes as key , then will it be a composite key ?
    Like if we created Entity "project", and then create following attributes
    Dept (Key)
    ProjectName (Key)
    Description
    Then will Dept and ProjectName together form a composite key ? or they will be individual keys for the project?
    Thanks
    Ashutosh Rastogi

    Hi Ashutosh,
    I think they would form a composite key.
    In fact the other day we were developing a PurchaseOrder entity service and by mistake chose poNo and vendorNo both as keys. Now we had a findByVendorNo operation which was returning a list of POs and we had only mapped the po from the BAPI to the attribute. Everything was hunky-dory during design time, we were able to build and deploy but while testing it using the service browser, on "execute query" CAF returned us an error. This was even though poNo was unique for every record.
    Regards,
    Parag.

  • Obejct key mismatch between webservice and entity service

    Hi
    I created one web service using entity service in one caf project. Now i created another project. I have one entity service in this project which is using the previous web service. when i am testing my second project using service browser, I am getting object key values which are different from what i am getting using web service browser.
    Anyone has any idea regarding this?
    Regards
    Saurabh

    Hi Sauragb,
    the different object keys is normal, because even when you apply remote persistency caf core stores the "startup" attributes in an database. So when using a entity service you will always have attributes like key, createdBy, lastChangedBy... stored in lokal CAF Database.
    And that's why you have different keys.
    best Regards,
    Rene

  • How to access the Web Service Browser

    Hi,
    I need to access the Web Service Browser to generate a Web Service Description.
    How can I do it?
    I use the follow url:
    http://<host_name>:<port_number>/sap/bc/bsp/sap/WebServiceBrowser/search.html?sap-client=<relevant_client>
    but I can't say how to determine values for the three placeholders.
    Help me please.
    THANKS

    Hi Andrea,
    you can access the web services in sap transaction SICF. Then right click on the
    service and choose "test". The hostname is the host on where the sap system
    runs.
    The port ´number can be seen in transaction SMICM -> shift + F1. Here you can see
    the portnumer assigned to the HTTP protocol.
    And the client is the sap client (standard client) for which the service is configured.
    Hope this helps.
    KR,
    Andreas

  • Error after Deploying a new Entity Service

    After deploying an entity service and testing it via the testtool the following error occured. Do you have an idea about the reason for this strange behaviour?
    Thanks in advance.
    ERROR. Exception thrown in method create. The transaction is marked for rollback.: javax/jdo/InstanceCallbacks -
    Loader Info -
    ClassLoader name: [siemens.com/sm3kshtlog] Parent loader name: [Frame ClassLoader] References:   common:service:http;service:servlet_jsp   service:ejb   common:service:iiop;service:naming;service:p4;service:ts   service:jmsconnector   library:jsse   library:servlet   common:library:IAIKSecurity;library:activation;library:mail;library:tcsecssl   library:ejb20   library:j2eeca   library:jms   library:opensql   common:library:com.sap.security.api.sda;library:com.sap.security.core.sda;library:security.class;library:webservices_lib;service:adminadapter;service:basicadmin;service:com.sap.security.core.ume.service;service:configuration;service:connector;service:dbpool;service:deploy;service:jmx;service:jmx_notification;service:keystore;service:security;service:userstore   interface:resourcecontext_api   interface:webservices   interface:cross   interface:ejbserialization   sap.com/cafcore   library:cafmetamodellib   library:cafruntimeapilib   sap.com/cafruntimeear Resources:   C:\usr\sap\P7D\JC00\j2ee\cluster\server0\apps\siemens.com\sm3kshtlog\EJBContainer\clientjars\clientsiemens.comsm3kshtlogejbmodule.jar   C:\usr\sap\P7D\JC00\j2ee\cluster\server0\apps\siemens.com\sm3kshtlog\EJBContainer\applicationjars\siemens.comsm3kshtlogejbmodule.jar   C:\usr\sap\P7D\JC00\j2ee\cluster\server0\apps\siemens.com\sm3kshtlog\src.zip Loading model: {parent,references,local} -
    The error occurred while trying to load "com.siemens.sm3k.shtlog.besrv.sigdatsource.SigDatSourceJDO".:

    Hi Samir,
    you could be right...
    it could be, that our metadata are inconsistent, because we had before problems with the automatic code generation.
    What should we do, if we have such a inconsistency of our ejbmodule, dictionary and metadata model?
    is there a way to repair the project?
    Undeploy and Redeploy doesn't have an effect on this.
    We cannot start again, because we put in 10days of development?
    Thanks for any help.
    Greetings Jens

  • In application services i am using entity services

    hi all
    i have created application services in entity services i have created findAll ()method that method i have accessed in application services by
    getEntityServices.findAll .and i have made application service as a webservices but when i am testing this method in wsnavigator
    this method gives error.please reply soon
    com.sap.engine.services.webservices.wsnavigator.WSNavigatorException: null
    Exception id: [02004C4F4F50004E000006FA00000E4000042DBF06435C4C]

    Hi, I tested the application using the CAF Runtime Configuration service test and it was an authorization Issue. The entity was set to check permissions. I disabled this in NWDS and it works fine now

  • Error in Accessing Service Browser in CAF

    I am trying to accessing Service browser from test tools in CAF.I am getting Sevurity warning as Access forbidden.So please resolve this issue.
    Thank you,
    Murthy.

    Hi,
    You need to assign the required roles to your user. Check the following links for more details:
    [SAP Network Blog: Setting up Roles for CAF, GP and Visual Composer|/people/ashutosh.rastogi/blog/2006/11/25/setting-up-roles-for-caf-gp-and-visual-composer]
    Thanks,
    Dipankar

  • CAF Service browser doesn't show any available services

    Hi All,
      I have developed a small application using CE 7.1 SP03.I want to test my Business Object services and application services using CAF ServiceBrowser. I have build and deployed the application and got a status that deployement had happend sucessfully. But the moment I start ServiceBrowser, I can see that Application Services list is empty. Could you please tell me why it is so?Am I missing any configuration or something like that?
    Regards,
    Prajesh

    Hi,
    Application service methodes can be devided in to two types:
    1) Methodes with return values.These will be shown in the available services part.
    2) Methodes without  return values.These will be shown in the Available actions for result service filed.
    If your method is not shown in these two areas, I think you have not generated and bulit your application properly.Once again generate, build and deploy it.
    Go through this help doc.Te[Testing services with Service Browser |http://help.sap.com/saphelp_nwce10/helpdata/en/4a/f707411c5ad349e10000000a1550b0/content.htm]
    Sampath

  • How to represent foreign key relationship between entity services

    Hi All,
    I have two entity services sbu and lob with remote persistensy(web service).In the sql database also i have these two tables.
    lob table attributes: lobId and lobName.
    sbu table attributes:sbuId,sbuName,and lobId.Here lobId a is foreign key referring to primary key of lob table.
    I want to represent this in the entity services.
    Can you plz tell me how can i do this?.
    Thanks
    Sampath.G

    Hi Sampath,
    to avoid creating a lob entity set the lobId and the timestamp attributes. because this is not smoothly done in the service browser, continue writing your UI.
    in old caf implementation this blog serie gives you a short overview...
    /people/raphael.vogel/blog/2006/05/18/writing-a-betting-pool-application-for-the-soccer-world-cup-2006-part-i
    /people/raphael.vogel/blog/2006/05/18/writing-a-betting-pool-application-for-the-soccer-world-cup-2006-part-ii
    /people/raphael.vogel/blog/2006/05/19/writing-a-betting-pool-application-for-the-soccer-world-cup-2006-part-iii
    /people/raphael.vogel/blog/2006/05/21/writing-a-betting-pool-application-for-the-soccer-world-cup-2006-part-iv
    Regards, Jens

Maybe you are looking for