cancel
Showing results for 
Search instead for 
Did you mean: 

GWPA OData service creation basics

Former Member
0 Kudos

Hello experts,

I am just starting with GWPA for Eclipse. Got it all setup, deployment to the Gateway Management Cockpit is working fine, and my Eclipse is connected to my Derby database that running on SMP3.0 server. I have a table wms_table with comuns col_1, col_2, col_3 and I want to create an OData service that will be exposing this data.

How do I go around creating an entity that will be correctly configured for this setup? I have followed the guide at SAP NetWeaver Gateway Productivity Accelerator but it doesn't say anything about the entity creation itself. I understand the entity set needs to have the same name as the table and the properties should correspond to the column names.

I did all this, built the service, deployed it to the cockpit, and activated it. Opening the service document gives me the expected result:

<service xmlns="http://www.w3.org/2007/app" xmlns:atom="http://www.w3.org/2005/Atom"xml:base="http://<host>:<port>/gateway/odata/sap/<Service Name>;v=1/">

<workspace>

     <atom:title>Default</atom:title>

       <collection href="wms_table">

          <atom:title>wms_table</atom:title>

     </collection>

</workspace>

</service>


But then when I access the entity set collection http://www.w3.org/2005/Atom"xml:base="http://<host>:<port>/gateway/odata/sap/<Service Name>;v=1/wms_table I get following error:


<error xmlns="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata">

<code/>

<message xml:lang="en-US">An exception occurred.</message>

</error>


Stack Trace:

com.sap.core.odata.api.ep.EntityProviderException: com.sap.core.odata.api.edm.EdmSimpleTypeException

  at com.sap.core.odata.core.ep.producer.AtomEntryEntityProducer.createEntryKey(AtomEntryEntityProducer.java:464)

  at com.sap.core.odata.core.ep.producer.AtomEntryEntityProducer.createSelfLink(AtomEntryEntityProducer.java:442)

...

Any idea what I am doing wrong? Also redeployment of a service from the Eclipse never has any effect after changes applied and regeneration of the deployment package I always have to recreate the project under different name.

Any help much appreciated.

Regards,

Frank

Accepted Solutions (0)

Answers (1)

Answers (1)

fenil_doshi
Participant
0 Kudos

Hi Frank,

I am also facing the same issue with the one of our services, I got the error from the Server Logs. Can you please suggest what might have gone wrong if you have found out the solution then can you please share with me as well.

Regards,

Fenil.