Quantcast
Channel: SCN : All Content - SAP Gateway
Viewing all 2823 articles
Browse latest View live

Please Clarify on $filter, $expand, $Read $Query

$
0
0


Hello Every One,

 

I have a requirement of passing multiple inputs and getting output as multiple structures.

 

Suppose like, if i am giving cust no, company code, credit control area as input and in the output i am getting results in two structures in my custom RFC, till here it is working fine.......the same output how can we replicate in gateway service builder

 

i know that we cannot do query operation as it allows only single input or filter can be applied on the same input.

 

I assume that this can be done using Read and Expand operations. Please guide me how to proceed further, or any othe possible ways to achieve this.

 

Passing multiple inputs and getting multiple structures as output using SEGW?

 

 

Thanks,

Vijay


How to implement read and query operation together in segw?

$
0
0

Hi,

 

I am trying to implement read operation which exports table as query result.

I have done the same using SE80 shown below.

 

 

Capture.PNG

 

Is there any step by step guidelines to do this?

What is association in segw?

Issue with Deep Insert ...

$
0
0

Hello Experts,

 

I am using DeepInsert Method for Creating Return Order Header and Items Creation(Parent and Child) relation that too based on a Existing Return order creation RFC. I am getting 500 internal server error as "No valid source context supplied" and In gateway error log "DeSerialization of XML Failed via transformation 'ID'" . Also I tried to keep the edm core type abap field for date as Nullable & Internal type as Date , decimal values with Packed but it's not accepting to change the datatype as it is different from Abap Type.

 

In Detail:-

I have 5 Entitysets for Header,Partner,Items,Conditions,Schedues.

Out of them I am using Header Entityset in the POST URL(http://host:port/sap/opu/odata/ZRETURNS_SRV/HeaderCollection)

and passing Header, Items,Partners,conditions,schedules inline entries via rest client based on http://scn.sap.com/docs/DOC-22305 .

 

Is that approach correct of having 5entity sets and passing only HeaderSet in URL ? The below Request Body shows the Inline entries belonging to all the Entitysets. So here the doubt arise , the way of passing the Inline entries is correct or any other approach for different entitysets.

 

URL:-http://host:port/sap/opu/odata/ZRETURNS_SRV/HeaderCollection

RequestBody:-

<?xml version="1.0" encoding="UTF-8"?>

<atom:entry

xmlns:atom="http://www.w3.org/2005/Atom"

xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices"

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

<atom:content type="application/xml">

<m:properties>

<d:DocType>RE</d:DocType>

<d:SalesOrg>1000</d:SalesOrg>

<d:DistrChan>10</d:DistrChan>

<d:Division>10</d:Division>

<d:DateType>1</d:DateType>

<d:OrdReason>101</d:OrdReason>

<d:PartnRole>AG</d:PartnRole>

<d:PartnNumb>0000000011</d:PartnNumb>

</m:properties>

</atom:content>

<atom:link

rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/SOItems"

type="application/atom+xml;type=feed"

title="Header_Items">

<m:inline>

<atom:feed>

<atom:entry>

<atom:content type="application/xml">

<m:properties>

<d:ItmNumber>000010</d:ItmNumber>

<d:Material>P500042</d:Material>

<d:Plant>1000</d:Plant>

<d:StoreLoc>1000</d:StoreLoc>

<d:TargetQty>5.000</d:TargetQty>

<d:TargetQu>EA</d:TargetQu>

<d:ShortText>JACK DANIELS WHISKEY</d:ShortText>

<d:MatlGroup>50200000</d:MatlGroup>

<d:CondStNo>011</d:CondStNo>

<d:CondCount>01</d:CondCount>

<d:CondType>PR00</d:CondType>

<d:Currency>USD</d:Currency>

<d:ReqDate>11-11-2013</d:ReqDate>

<d:ReqQty>5.000</d:ReqQty>

</m:properties>

</atom:content>

</atom:entry>

<atom:entry>

<atom:content type="application/xml">

<m:properties>

<d:ItmNumber>000020</d:ItmNumber>

<d:Material>P500042</d:Material>

<d:Plant>1000</d:Plant>

<d:StoreLoc>1000</d:StoreLoc>

<d:TargetQty>5.000</d:TargetQty>

<d:TargetQu>EA</d:TargetQu>

<d:ShortText>BRANDY</d:ShortText>

<d:MatlGroup>50200000</d:MatlGroup>

<d:CondStNo>011</d:CondStNo>

<d:CondCount>01</d:CondCount>

<d:CondType>PR00</d:CondType>

<d:Currency>USD</d:Currency>

<d:ReqDate>11-11-2013</d:ReqDate>

<d:ReqQty>5.000</d:ReqQty>

</m:properties>

</atom:content>

</atom:entry>

</atom:feed>

</m:inline>

</atom:link>

</atom:entry>

 

Appreciate your help.

 

 

Thanks,

Uday.

Date format in Request URL

$
0
0

Hello Experts,

 

Can anyone let me know passing Date as Input Parameter in Odata Request URL. I tried with different formats . I am getting repsonse as "Invalid parametertype used at function 'eq' " . In structure declaration Date field Edm.Core Type is Edm.DateTime and for Abap type tried with both Data Element and InternalType . In Back-end, RFC with Input Date is having Date with type ERDAT. 

 

Appreciate your help.

 

 

 

Thanks.

How to update "Data Source Parameter"

$
0
0

Hi

In my mapping, I have mapped several fields in my gateway to a FM from another system (remote).

 

After my mapping is done, and the service is running, we want to add a new field.

We have extended the FM with the new fields, and also added new entries in the properties of Gateway service.

 

But when I go to mapping, it is the old FM that I see.

How do I update the FM, so I can mapp the new fields?

 

Thanks


/Lars

Query similar to like operator

$
0
0

Hello All,

 

I have a query regarding Like operator in Abap . I am using the below code using like operator to fetch some data . For that RFC I need an Odata request URL which Inturn calls that RFC . Which String function i need to use ?

 

SELECT EBELN        "Purchasing Document Number

              EBELP        "Item Number of Purchasing Document

              TXZ01          "Short Text

              MATNR        "Material Number

              MENGE       "Purchase Order Quantity

              MEINS         "Purchase Order Unit of Measure

              FROM EKPO

             INTO TABLE T_EKPO

             WHERE EBELN  LIKE IM_PO_NUM.

 

 

I want to get all records which starts with '045'. I tried with below syntax.

http://host:port/sap/opu/odata/sap/ZPO_SRV/POSearchCollection?$filter=substringof('045' , ImPoNum) eq true and ImPlant eq ' ' .

Syntactically it's correct but not able to get data.

 

 

Appreciate your help.

 

Thanks.

CSRF Data with token but missing cookie

$
0
0

Hello everybody,

 

I'm working on a way to create and update entities with OData and Netweaver Gateway using the generated sources of the XCode Developer Tool.

 

When requesting the CRSF token and cookie, I only retrieve the token, the cookie is not present.

 

Can someone help?

 

Cheers,

Johannes

Can anyone tell me more about the compatibility of SAP Netweaver Gateway with underlying system

$
0
0

Hi everyone,

 

Can anyone tell me more about the compatibility of SAP Netweaver Gateway system if implemented in embedded or hub deployment ?

i.e, if I have a SAP R/3 Enterprise 4.7 system, can I install the gateway in embedded or hub deployment ?

 

I read about the compatibility based on its components like IW_FND, GW_CORE, IW_BEP, and IW_HDB which is very confusing. What I want to know is, whether we could deploy SAP Netweaver Gateway irrespective of the underlying system in any of the deployment method.

 

Thank you in advance for your help.

 

Regards,

Tijesh


Custom development in SAP Netweaver Gateway Service

$
0
0

Hi gurus,

I'm currently configuring a SAP Netweaver Gateway Service using SEGW. Our gateway version is 7.02.

As per the requirement we have to add custom codes into the _DPC_EXT class in our services. But when we re-generate the project, our custom codes were overwritten and lost.

Our temporary work-around  is to backup the codes/generate temporary version in SAP repositories but this becomes troublesome overtime as the gateway service grows bigger.

 

Is there any other way for us to preserve the custom codes?

 

Regards,

Nhan

How to pass data to a deep entity create call

$
0
0

In this quick guide i'm trying to explain how to create a structure with data for a deep entity create call in Odata.

 

Lets assume your collection name as Change request, this contains the hierarchy of entities.

Example:

Change_request

     {

        ATTRIBUTE 1

        ATTRIBUTE 2

            Material

               MATNR

               TXTLG

                     Classification

                              CLASS

                              CHARACTERISTICS

     }

 

In the Metadata you will get the name of the association(which is the name of the relation between the entities), you have to use the association nameinstead of the entity name in the JSON structure.

An example data looks like:

change_request{

          ATTRIBUTE1: VALUE

          ATTRIBUTE2: VALUE

          Association_name1:

          [

             TXTLG: VALUE  

           ]        

          Association_name2

            [
            CLASS: VALUE

            CHARACTERISTICS: VALUE             

             ]

}

 

Please note even you have a single entry for the sub entities it should be in an array.

How can I set a filter for my GET_ENTITY

$
0
0

Hi

Would it be possible to set a filter (or similar) for my GET_ENTITY, so I can decide my output.

Maybe so I only show my line 20 or what I put into my "filter"..

 

/sap/opu/odata/sap/ZGW_xxxxxxx_SRV_03/OrdDetSet('000010025783')

 

Thanks

Lars

What is the main purpose of SAP Netweaver Gateway?

$
0
0

Hi Experts,

 

We want to know about SAP Netweaver Gateway.

Please let me know where can we implement this ?

What is its main Purpose?

Can we use SAP Netweaver Gateway as a replacement to SAP PI for integrations between SAP and Non SAP systems? If so What type of integrations we can do with SAP Netweaver Gateway?

 

Thanks

Manaswitha

User name in gateway and ECC is mandatory

$
0
0

Hi Experts,

         One of the client is having the requirement like the user dont have access in the backend but he/she can approve by using the SAP Fiori.

 

For example : The userid for gateway is 'A' , but the user 'A' is not existing in backend.Is it possible to approve the PO using the SAP Fiori.

 

Thanks in advance.

 

 

 

Regards,

Myilraja

Service only returning one record, not whole table

$
0
0

Hello,

 

I am new to Netweaver Gateway, trying to set up our first Service.

My goal is to use our Solutions Manager (Version 7.02, SP12) system as our Hub and use it to call a Z RFC function RFC on our ECC system (Version 7.31, SP4). We are not planning on installing Gateway on the ECC system yet. The function is written to allow an input variable (Cost Center), and return a table with 4 fields in it(Store, ID, FirstName, LastName). I move the Storenumberin value to the Store output table to be returned so that I can prove the input goes in and can come back in output. I also return test values in the table if nothing is found indicating an error.

 

 

The Solutions Manager system has the GW_Core and IW_BEP modules.

 

I have used SEGW to import the RFC from the ECC system into an Entity Type.

The Entity Type has 4 Properties, StoreNumber, ID, FirstName, LastName (StoreNumberIn is the Input Parameter for the function, and the other 4 are the fields in the output Table). The Property StoreNumber is marked as the Key.

Screen Shot 2014-02-11 at 10.52.51 AM.png

I then created the Entity Set and made it addressable (based on other readings I had done).

I then Generated the Service Implementation.

 

I then Mapped the Read GetEntity, with StoreNumberIn as Input to the StoreNumber property, and all properties as Output.

Screen Shot 2014-02-11 at 10.57.15 AM.png

I then Mapped the Query GetEntitySet, with StoreNumberIN as input to the Input parameter of the function. I mapped the other 4 fields as Output to their respective function fields. Mapping is the same as Read Mapping.

 

 

I then added the service in the IMG (SAP Netweaver/Gateway/OData Channel/Administration/General Settings/Activate and Maintain Services) and made sure it was hooked to the correct System Alias.

 

I am testing using the Netweaver Service Explorer on the External Service Name.

When I try to Get Entity Sets, I click the entity Set and click Execute. It prompts me for Parameter, and has the Entity Set name there.

If I add ('1234') ( or any other value) to the Entity type, it executes and returns with only one record, the first record of the table. This should not happen.

Screen Shot 2014-02-11 at 11.25.49 AM.png

 

If i don't add any filter, I get multiple records back.

The way the function is designed, it should ALWAYS return 2 records. It is hardcoded for testing that way for now.

Screen Shot 2014-02-11 at 11.04.42 AM.png

Anyone have any ideas on what I should check?

Any Examples?

Any other discussions or blogs that I have not found yet and should check out?

 

Most of the ones I have found are all for working on the Local System, Not working doing a generic channel setup to a system that does NOT have Gateway installed.


I need to also return it as JSON. I am using  ?&$format=json   on the call to get it back that way. Is this the best way?

Can we default it to JSON instead of xml?

 

Thank you for your help,

Mike

SAP Fiori - PO Approval issue in workflow & Gateway

$
0
0

Hi Experts,

  

        I developed a custom workflow for PO approval applicaiton in Fiori.

 

In workflow am using the user decision step to approve/reject.For this step standard itself proving the task 'TS00008267'.

 

By using this task we cant able to fetch the PO related value while running the PO approval application from the URL.

 

Because the table 'SWW_WI2OBJ' dosent hold the values for the user deciosn task id.

 

Am getting the error like the 'Purchase order not found for the woritem 00000123326'

 

Thanks in advance

 

 

Regards,

Myilraja


$filter from UI5 - Filter Property name does not match model property

$
0
0


Hello,

 

we have quite a strange requirement. Due to some drill-downs from other applications it's not possible to specify the sPath of the filter in the filter object properly --> this means the parameter we will hand over will not always match the properties defined in the Odata Model.

 

We thought of some kind of workaround which might can help us. I have defined a dummy "FILTER" property in the model, which will contain a separate  filter string

 

--> e.g.

l_filter_string = "$filter=substringof(%27Source_Loc%27,SOURCE_LOC)%20and%20substringof(%27Act_Loc%27,ACT_LOC)%20and%20substringof(%27Del_no%27,DEL_NR)%20and%20substringof(%27Product_ID%27,PRODNR)%20and%20substringof(%27TRACKING_ID%27,TRXID)%20and%20substringof(%27PO_NO%27,PO_NR)%20and%20substringof(%27REason%27,REASON_CODE)%20and%20substringof(UPSsad9999hflhasdfjh,FILTER)%20and%20ONTIME_STATUS%20eq%20%27NOT_OK";

 

when receiving the data in the /IWBEP/IF_MGW_APPL_SRV_RUNTIME~GET_ENTITYSET I will evaluate the it_filter_select_options which will be used to contruct the select to the DB. Is there a possibility to somehow append and split this filter string in a way that we get the separate values in the /IWBEP/IF_MGW_APPL_SRV_RUNTIME~GET_ENTITYSET I will evaluate the it_filter_select_options table.

 

at the moment I receive the filter string in the Property "FILTER"

it_filter_select_options.jpg

 

this is what I want to split up and add to the it_filter_select_options table as separate properties:

it_filter_select_options_String.jpg

 

Thanks for your help.

Regards Marco

Query on installation of Netweaver GW

$
0
0

Hi Experts,

 

I have a query on installation of NW Gateway 2.0. I have BW 7.3 SP5 and ECC 6.

 

I want to expose my BW query as an ODATA service. So for that I want to install NW gateway.

 

But which is the best approach?

1) Install on BW

2) Install on ECC

 

We have tried to install GW 2.0 SP4 on BW 7.3 SP5, but not able to do that. I think BW 7.3 is not supported for GW 2.0.

 

I also heard that we can install gateway on ECC and then RFC through, we can expose BW's query into ODATA. Is it correct?

 

Please guide me, I am new to this.

Regards,

Niket Talati

Connecting Eclipse to ui5 Team Repository (Mac)

$
0
0

Hi there.

 

Has anyone successfully checked-in/checked-out a ui5 application from Eclipse in to Application Server using the Getaway Plugins on Mac?

 

From my experience this far, there appear to be incompatibilities between the Gateway plugins and SAPGui Java where not all the fields are pulling through from the connection profile settings on SAPGui Java into the Team Sharing wizard in eclipse.

 

Anyone had the same experience or managed to get this working, please connect.

 

Sergio

SAP GWPAM Excel - Solution Manager Integration

Data Model generation issue

$
0
0

Hi,

 

We are trying to generated our data model after going the mapping in the service implementation. We are using transaction SEGW to create our data model.

 

We get these errors when trying to generate our data model,

 

"Failed to generate the backend operation proxy for RFC ..."

"Remote RFC signature could not be read"

 

Any advice would be greatly appreciated, please let me know if you need any more information.

 

Thank you for your help.

 

Regards

Jing Jing Tao

Viewing all 2823 articles
Browse latest View live


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