Quantcast
Channel: SCN : Unanswered Discussions - SAP Gateway
Viewing all 1745 articles
Browse latest View live

Invalid key predicate type for 'Sdate'. Expected type is 'Edm.DateTimeOffset'

$
0
0

hi

 

we are trying to test Odata service in /iwfnd/gw_client

 

url is /sap/opu/odata/sap/ZDATACOUNT_SRV/DatacountSet(datetime'2015-07-30T00:00:00')

 

operation GET

 

getting error

 

Invalid key predicate type for 'Sdate'. Expected type is 'Edm.DateTimeOffset'


thanks in advance for any suggestion



CSRF Token - Service User, 403 in GW

$
0
0

hi,

 

I have an ui5 application running under a service user in icf node (setup directly in the icf node) - and this triggers an error 403 error while trying to execute the modifying operation.

 

The reason behind it is that internally, the sap system is calling some c based function and returns a silent error sy-subrc = 2 on the check for the acquisition of the token - which seems to be rather invalid, considering the setup.

 

Setup is somewhat like:

 

- BSP Node: Service User, Auth. Method has Service Data;

- OData Nodes: Service User, Auth. Method has Service Data;

 

Execution wise, all works - it identifies the user and no problem occurs.. However, it seems that the CRSF-Token: Fetch "requires" some other Procedure to be in place other than Service Data.

 

Explaining a bit further, have the exact same request either pushing down an Authorization header or having the browser authenticate using a Basic Auth. returns a SSO cookie which is "handed over" on the subsequent request for the token fetch - having the cookie setup allows GW to generate a token as expected.

 

The opposite case (where the logon happens in the icf node using Service Data) does not generate the SSO cookie (there is no set-header for the cookie coming back) - hence, the X-CSRF-Token: Fetch returns a "blank" X-CSRF-Token - it doesn't even fail, it fails to acquire one... the "bypass" should take into account the authentication procedure used? - IMO, I shouldn't even be bothered with such BS protection, but it seems GW sort of 'enforces it' and it's kinda hard for me to tell folks here we should disable it - not to say, even thou is sort of "dummy" to have such for a Service User maybe keeping it in place would easy up changes in future if they want identified access (user based access).

 

 

Options I have atm:

- disable CSRF either in a custom handler;

- disable CSRF using the gui configuration option as per 7.4 docs;

 

 

Has anyone faced similar issue? - Any help to overcome this problem is highly appreciated, I don't want to disable the validation mechanism but I need to bypass and somehow "trick" the c kernel call.

 

 

 

Cheers,

- Dan.

Issues in Netweaver Gateway concepts.

$
0
0

Hello Gateway Gurus,

      I had been carrying out OData service activities in Netweaver Gateway, Facing issues in understanding the functionalities and concepts in it.. I hope this post will be helpful for getting all basics understanding cleared.


NOTE: Please consider doubts mentioned below as Independent of each other also these images are not related to each other.


1. I am bit puzzled in the properties section of the data model... as in what is the relevance of the checkboxes as shown below picture..  I have noticed these reflected in $metadata of the service as well).

 

 

pic 1.JPG

 

2. Regarding the other confusion its related to cardinality..

When we do we go for Cardinality as "N" and when for Cardinality as "M"

 

11 cardin.JPG

 

3. I have used the following lines of code many times...

sharing the snapshot for the same.

 

but yesterday I was in worry about what the IO_EXPAND-> Compare_to mean as I didn't know its working..

also the use of lv_compare_result ???

 

like for example, if I have to specify two children , but Even If I specify 'SOItems' here , I get 'SOSchedules' as well  ...

 

 

IO data.JPG

 

Thanking you in advance,

Hope to get many helpful hit on this..

 

BEST REGARDS,

Pavan Golesar.

Hi everyone

$
0
0

Iam looking to fetch the content which is present in odata services which is in json format to solr so i need to write connector in java plz can anyone guide me in writing java connector.

Hi everyone,

$
0
0

Iam trying to fetch the data from odata and display in solr(it is a search engine) can anybody guide how to do this.

Why OData when there's Webservice?

$
0
0

Ok, I have been trying to learn ODATA from past one week and I have understood that we can make use of Odata by RFC/BOR and DDIC Structures.

By making use of DDIC structures/tables we can code in the respective methods(by redifining) to perform CRUD operations and by RFC well I haven't learned it precisely, I followed the exact same steps mentioned by Mr Volker Drees but I'm getting error 500.

FYI the link is Step-by-step guide to build an OData Service based on RFCs – Part 2

There's not much data available other than that for working with RFC/BOR.. I mean there needs to be much simpler demonstration with a very simple RFC.

Which makes me think why odata and why not webservices.. What advantages Odata has over webservices.

Also, if it's not too much to ask please try to address my issue by giving a simpler Odata example using an single RFC, you know just give an input and get an output kinda example.

Regarding ODATA and RFC calls

$
0
0

Hi All,

 

I am developing a Odata to fetch Vendor invoices based on the BAPIS:

 

BAPI_INCOMINGINVOICE_GETLIST

BAPI_INCOMINGINVOICE_GETDETAIL

 

So in the Odata I created one entity type for Invoice list, and get the list of invoices based on BAPI: BAPI_INCOMINGINVOICE_GETLIST, however when displaying the item data related things, I have ITEM DATA, ACCOUNT DATA, TAX DATA as return tables of the BAPI : BAPI_INCOMINGINVOICE_GETDETAIL.

 

Now my Question is since the single BAPI Calls returns entire details about the invoices, Can I fetch all the data of a vendor invoice in single call and use the same in my Fiori App? If so How the Nested Tables should be read from the ODATA??

 

 

And the second question is that, in Couple of blogs I read that OData structures should be Flat and cannot be nested, if that is the case how can I get the entire data in single call??

 

 

I can use association and navigations to drill down however, for each entity the BAPI is called multiple times, will that not be perfomance issue??

 

Kindly advise.

 

Regards

Manoj

Odata collection to entity navigation

$
0
0


Hi Guys,

 

I am very new to odata and recently i am looking at a requriement that goes something like this (using sflight as example). It needs to returns records from sflight and it also need to able to return a txt file which contains records from sflight.

 

So i created a entity type of Sflight which contains all the properties from the sflight table, then i created an entity of DataFile of media source type to enable the download of the txt file.

 

According to sap odata book, navigation can be from collection/entity to collection/entity, so i am trying to create M to 1 navigation from collection of Sflight to single Datafile entity. So that i can use $filter at the Sflight collection and pass it to DataFile for file generation.

 

But i can't seem to find out how to do that.

 

1. Any one got an example on how to create a navigdation from collection to single entity? When navigation is triggered, the get_entity method of DataFile is triggered, but i wont be able to get the list of Sflight that i need to generate the txt file.

 

2. Is there a way to use media source at collection level in stead of entity level?

 

3. Any other sugguestion to this requirement is most welcome? but i try to use media source instead of returning edm.binary.

 

thanks


Maximum no. 300 of systems reached

$
0
0

Hi,

Could someone help me with this issue please?

 

Our business users access Enterprise Portal to run BW Reports. This creates a new RFC connection in the BW ABAP backend and I could see the connection in the SM04 and SMGW screens. However some of these connections are not closed. They remain there forever until it reaches the maximum number of RFC connections and no users could run reports anymore.

 

Also, from the SMGW screen, when I click on "Go To > Logged on Clients", I could see list of clients, some of which are few days old. Even these are not closed and at some point they reach the maximum limit and below errors start appearing in SM21:

 

Maximum no. 300 of systems reached

 

As a workaround, we are currently doing an "End Session" in SM04 and "Delete Client" in SMGW

 

I don't want to increase the count in the parameters for maximum RFC's or maximum Clients' because if the connections are not closed, they would reach maximum limit again. I would like to understand why these connections are not closed.

 

Another interesting thing is our users also connect to ERP and SRM exactly the same way and we don't have any problems there. In fact in those system's SM21 logs I could see these messages:

 

HTTP/RFC session has been deleted following timeout.

 

I don't see similar messages in BW.

 

Your help will be much appreciated.

 

Thanks.

Aneeth

Gateway oData service -

$
0
0

Dear experts

I have a question on the metadata of an oData service. Here is the service I have

 

<edmx:Edmx Version="1.0" xmlns:edmx="http://schemas.microsoft.com/ado/2007/06/edmx" xmlns:sap="http://www.sap.com/Protocols/SAPData"><edmx:DataServices xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/
metadata" m:DataServiceVersion="2.0"><Schema xmlns="http://schemas.microsoft.com/ado/2008/09/edm" Namespace="MySalesOrders"><EntityType Name="SalesOrder"><Key> <PropertyRef Name="SalesOrderNumber" /> </Key><Property Name="SalesOrderNumber" Type="Edm.String" sap:label="Sales Order Number" Nullable="false" MaxLength="10" /><Property Name="TotalAmount" Type="Edm.Decimal" sap:label="Total Amount" Precision="16" Scale="3" sap:unit="Currency" MaxLength="10" /><Property Name="Currency" Type="Edm.String" sap:label="Currency" MaxLength="5" sap:semantics="currency-code" /><Property Name="CustomerID" Type="Edm.String" sap:label="Customer ID" MaxLength="10" /><Property Name="CustomerName" Type="Edm.String" sap:label="Customer Name" MaxLength="35" />

as you see, some of the properties have additional information like sap:label, sap:unit and so on. Are  these annotations???

Where can I use these information while building any UI5 app?

 

Thank you

Aakash

UPDATE_ENTITY method of /IWBEP/IF_MGW_APPL_SRV_RUNTIME issue..

$
0
0

Hello Gurus,

 

I came across a new method of  /IWBEP/IF_MGW_APPL_SRV_RUNTIME Gateway Application Interface which is UPDATE_ENTITY.

 

I cannot trigger this method..

 

Can anyone share when can we trigger this method.??

 

like for create_deep_entity trigger on Header set for example.. likewise what can be the URI for hitting UPDATE_ENTITY.

 

Thanks,

Pavan G

Support for multiple attachments in a batch

$
0
0

Hello,

We are working on a requirement to receive multiple attachments for a request along with payload via odata service. I would like to know if its possible.

1. To process multiple attachments with a batch request

2. To process multiple attachments with a batch request + a payload

 

If above is possible, how can i make sure that i can read attachments in a batch request. My understanding is that i need to redefine CREATE_STREAM. But how is this triggered for batch processing. I see some operation types in the domain /IWBEP/MGW_OPERATION_TYPE and it supports create stream. But how can i read stream data with a deferred processing(my plan is to use /IWBEP/IF_MGW_APPL_SRV_RUNTIME~CHANGESET_PROCESS ). When i use deferred mode framework does not call standard methods CREATE_ENTITY, DELETE_ENTITTY etc..

In case of entity i know that i have to use interfaces  /IWBEP/IF_MGW_REQ_ENTITY_C, /IWBEP/IF_MGW_REQ_ENTITY_D, /IWBEP/IF_MGW_REQ_ENTITY_P

/IWBEP/IF_MGW_REQ_ENTITY_U to get payload. But can't find such interfaces to play with stream.

 

Some blogs on scn suggests to send only one attachment in a request, loop thru all attachments and store in temp db.

Any suggestions..

 

Regards

Pradeep

multiple bw queries into one Gateway service

$
0
0

Hi all,

    i follow this article Transform SAP BW Queries into OData Service: Part 1 - Generation and Activation to create a gateway service for my mobile development, as the mobile solution i use ,which is smp ,only consume one gateway service for one app. However, when i redefine the BW Query , i found i can only redefine on BW query into one gateway. But we really need multiple query for our mobile app.

 

     so is there any possible to bind multiple BW queries into  one OData service? thanks in advance.

 

 

Regards,

Billy

Maximum size of a file in attachment

$
0
0

Hi All,

  I would like to know the maximum size of an attachment that can be uploaded in net weaver gateway client . Say for example if I try to upload 300 mb file in gateway client, I get ' file upload error' . Is this maximum size is different for each mime type? If a large file has to be uploaded,is that some workaround is available?

 

Thanks

Gayathri

UpdateEntity

$
0
0

Hi All,

 

I am facing issue in UpdateEntity Method in Gateway service call.


I am using SAP Gateway Foundation Version : 7.40

 

I had created Create Deep entity for  Customer(Header) and Partner function(Details), which is working fine but same

thing when i am calling PUT Method using UpdateEntity it gives me error :

 

Inline component is not defined or not allowed (HTTP PUT)

 

Gateway oData Service for update:

/sap/opu/odata/sap/CUSTOMER1/SOHeaders(CustomerID='0000000547',BNAME='M1018991')

 

If i pass only header part in XML request then Update entity is working fine but after adding partner function details it is giving above mentioned error

 

I had attached the XML ..

 

Kindly suggest ,what could be the issue..

 

 

Regards

Vivek


Moving from embedded deployment to central hub

$
0
0

Hi!

 

I would like to know if any of you migrated a SAP Fiori implementation from embedded deployment to central hub. If yes what are the main tasks?

Or will I have to reploy SAP Fiori implementation from scratch.

There's a similar post Netweaver Gateway Installation options - Embedded/Central Hub?  about this issue but it's inconclusive.

 

In this scenario we have SAP ERP 6.07 that already has SAP NW gateway 7.40 component.

 

cheers

fernando

Maintenance and governance of oDATA repository

$
0
0

   Hi All,

I want to ask you if there is any tool and methodology for oDATA services. In our company we can see that different teams create oDATA services and the functionality of some of them is overlapping, are there any tools for that?

 

Many thanks Jiri

SEGW: Custom Import of Model from XML doesn't work

$
0
0

Hi,

 

I'm creating a new OData Service in SEGW.

The modeling has been done in Eclipse with the help of the OGEE Odata Modeler.

 

The first import of the generated XML file in SEGW works fine.

I then change for example the max length property of an entity's string attribute in OGEE and export as XML again.

Now when importing this changeg XML in SEGW I use the "Custom Import" option of the import wizard in order not to overwrite the entire model but to manually select the properties I want to import.

 

My problem is that the property which I changed in OGEE before is displayed as "equal" in the import wizard and thus can't be selected to import / overwrite the existing property.

 

Is this a known problem or am I missing something here?

 

BTW: If I change the name of the property SEGW correctly determines one deleted and one new attribute in the custom import wizard, but changing the length property doesn't seem to be recognized correctly.

how we will get data for all Business partners in odata service (MCF) instead of defining one by one in SU01?

$
0
0

In ERP_UTILITIES_UMC ---- ERP UTILITIES multichannel  service

When I am calling this URL .

URL:/sap/opu/odata/SAP/ERP_UTILITIES_UMC/Accounts

I am getting status code 200.But it is not showing any data in it.

So we  are maintain  Business partner  inSU01  user reference like below

BUS1006              Business Partner              103.

If we passing like below we are getting data for that particular Business partner only.

My Question is how we will data for  all Business partners instead of defining  one by one in SU01?

Gateway odata path permissions HTTP GET/POST/UPDATE/DELETE

$
0
0

Dear community,

 

when developing a SAP gateway application, I was wondering whether there is an efficient, maintainable and customizable way to control user permissions at runtime to regulate which odata paths can be used by a certain user, i.e.

 

 

 

Is there standard way to change runtime permissions for a user to be able to call certain odata resources of a SAP gateway service, other than manually writing code in every service implementation method to check if the request is allowed?

For example, based on some setting in customizing, the odata paths below /foo and /bar for user x should be forbidden, i.e. HTTP GET/POST/DELETE <host>:<port>/foo/test and HTTP GET/POST/DELETE <host>:<port>/bar/test should yield HTTP 403 for user x, but HTTP GET/POST/DELETE <host>:<port>/something should be OK.

Is there a way where this can be controlled at a single place rather than being required to implement a check in every method implementing the odata requests?

Looking forward to your suggestions,

Sebastian B.

Viewing all 1745 articles
Browse latest View live


Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>