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

Authentication issue in SMP from Windows AD (Active Directory)

$
0
0

Hello Gurus,

 

Current we are implementing SMP platform Native mobile app. I required your advise and suggestions for below scenario :

Current design :

Have ECC (Installed in different box) and NW (installed in different box) trusted RFC connection maintained between ECC & NW to consume ODATA services.

 

1) Our mobile app will authenticate through windows AD server. (user maintained / created as "MobileUser1" in AD and ECC server) *User id is same in both the servers

2) Is it mandatory to maintain the same user "MobileUser1"  in (NW server) ? to access for creating the orders, pull / sync the data

3) If we maintain "Mobileuser1" in NW server then how can we handle if AD user password changes then it's mandatory to change and create the same password in NW & ECC??

 

Any Help will Appreciated.

Thanks in Advance.

 

Regards

PavanG


How to access request object in Model Provider Class

$
0
0

Dear specialists,

 

I want to define the data model of my OData service dynamically depending on an URI paramter of my HTTP request. But so far I did not find any possibility to access the request object in the model provider class.

 

Does anybody has a hint for me?

 

Many thanks in advance.

 

Best regards,

Juergen

Can not fully edit Gateway project of other developer.

$
0
0

I work in a shared team on multiple Gateway projects. So, we might have to edit each others projects depending on individual availability. However, I can not fully edit another developers Gateway project. The most noteable restrition is the disablity to reimport entities (see attachment).

 

He is the creator of project. We have the same developer permissions. The project itself has not been transported yet. Editing his project created a new transport.

 

Can you help me?

 

Thank you.

Implementing security in gateway services

$
0
0

What is the best practice to implement security for o-data services ? I want some users to have access to GET Entity / Entity Set but no access to CREATE / DELETE /UPDATE. For other set of users, I want them access to CREATE & UPDATE but no DELETE for the same entity.

 

What is the best practice to implement security at service level ?

How to delete a GW service on GATEWAY hub?

$
0
0

hi experts,

 

In the /FIND/MAINT_SERVICE, how to delete a existing service? Each time I tried this, I will get some error like:

Delete Definition Assignment(s) first

and others.

So what is the correct way/steps to delete a existing service?

 

Thanks.

Download Functionality in get_stream

$
0
0

Hi

 

I am displaying multiple invoice numbers like

 

CheckBox         Inv no        quantity ..................................

X                         1               10.00

X                         2               20.00

X                         3               3.00

                            4              40.00

X                         5               50.00

 

in this case i need to download all invoice forms based on NAST configuration.

 

Is it possible through get_stream method? is there any other solution?

 

Please suggest

Error: Invalid or no assignment to system datatype found

$
0
0

Hi All,

 

I am trying to get some data from the back-end with SAP Gateway. I have created a data model, generated and implemented the get_entityset for my entity. When i call the service, the output data is filled correctly after the get_entityset is executed.

The problem appears when the Gateway tries to convert the data into JSON format. An exception is thrown and an error appears in the Gateway log too, which states that there is an invalid or no assignment to system datatype. I checked the data model in the Gateway, regenerated the runtime artifacts, but I still get the same error.

 

This is my data model:

Capture.JPG

Capture.JPG

 

Any ideas what the problem might be?

 

Thanks,

Szilamér

How to save data and file in one shot?

$
0
0

Hi,

I have a requirement that user enters some data and attaches his file. I want to store file and other text data at one time.How to achieve it?

Thanks.


OData model for a simple Remote function module

$
0
0

Hello all,

 

          I want to create an application SAPUI5 which takes some inputs and gives output results. For that I have a function module with import and export parameters. I want to know the simplest way to create an OData model which uses this RFC (code below). For example- How many entities should I have? What CRUD functions do I have to define and things like that. Any kind of knowledge would be of great help as I am new to this.

 

 

 

 

FUNCTION zisu_ui5_change_objects.

*"----------------------------------------------------------------------

*"*"Local Interface:

*"  IMPORTING

*"     VALUE(OBJECT_TYPE) TYPE  TCDOB-OBJECT OPTIONAL

*"     VALUE(CHANGED_BY) TYPE  CDHDR-USERNAME OPTIONAL

*"     VALUE(DATE_FROM) TYPE  CDHDR-UDATE OPTIONAL

*"     VALUE(DATE_TO) TYPE  CDHDR-UDATE OPTIONAL

*"     VALUE(TIME_FROM) TYPE  CDHDR-UTIME OPTIONAL

*"     VALUE(TIME_TO) TYPE  CDHDR-UTIME OPTIONAL

*"  TABLES

*"      IT_CHANGE_OBJECTS TYPE  ZISU_T_UI5_CHNGOBJ OPTIONAL

*"----------------------------------------------------------------------

   DATA: it_chngobj TYPE STANDARD TABLE OF cdred,

         ls_chngobj TYPE cdred.

   DATA: lt_cdhdr      TYPE STANDARD TABLE OF cdhdr,

         ls_cdhdr      TYPE cdhdr,

         ls_name       TYPE bapiaddr3,

         lt_cdpos      TYPE STANDARD TABLE OF cdpos,

         ls_cdpos      TYPE cdpos,

         ls_out        TYPE zisu_ui5_chngobj,

         lt_tab        TYPE TABLE OF dfies,

         ls_tab        TYPE dfies,

         lt_username   TYPE RANGE OF cdusername,

         ls_username   LIKE LINE OF lt_username,             "#EC NEEDED

         lt_objectclas TYPE RANGE OF cdobjectcl,

         ls_objectclas LIKE LINE OF lt_objectclas,           "#EC NEEDED

         lt_objectid   TYPE RANGE OF cdobjectv,

         ls_objectid   LIKE LINE OF lt_objectid,             "#EC NEEDED

         lt_tabname    TYPE RANGE OF tabname,

         ls_tabname    LIKE LINE OF lt_tabname,              "#EC NEEDED

         lt_return     TYPE TABLE OF bapiret2.

 

   TRANSLATE object_type TO UPPER CASE .

 

*CALL FUNCTION 'CHANGEDOCUMENT_READ'

*    EXPORTING

**      changenumber      = nummer

*      date_of_change    = DATE_FROM

*      objectclass       = OBJECT_TYPE

**      objectid          = objektid

**      tablekey          = tabkey

**      tablename         = tabname

*      time_of_change    = TIME_FROM

*      username          = CHANGED_BY

**      local_time        = local_t

**      time_zone         = tzsource

*      date_until        = DATE_TO

*      time_until        = TIME_TO

**    IMPORTING

**      et_cdred_str      = lt_cdred_str[]

*    TABLES

*      editpos           = IT_CHNGOBJ

*    EXCEPTIONS

*      no_position_found = 1

*      OTHERS            = 2.

*

*move-corresponding it_chngobj[] to IT_CHANGE_OBJECTS[].

 

 

   CASE object_type.

     WHEN 'CO'.

       ls_tabname-low = 'ES56'.

       ls_tabname-option = 'EQ'.

       ls_tabname-sign   = 'I'.

       APPEND ls_tabname TO lt_tabname.

       ls_tabname-low = 'ES55'.

       ls_tabname-option = 'EQ'.

       ls_tabname-sign   = 'I'.

       APPEND ls_tabname TO lt_tabname.

     WHEN 'IN'.

       ls_tabname-low = 'ES320'.

       ls_tabname-option = 'EQ'.

       ls_tabname-sign   = 'I'.

       APPEND ls_tabname TO lt_tabname.

       ls_tabname-low = 'ES31'.

       ls_tabname-option = 'EQ'.

       ls_tabname-sign   = 'I'.

       APPEND ls_tabname TO lt_tabname.

     WHEN 'CT'.

       ls_tabname-low = 'ES22'.

       ls_tabname-option = 'EQ'.

       ls_tabname-sign   = 'I'.

       APPEND ls_tabname TO lt_tabname.

     WHEN 'PR'.

       ls_tabname-low = 'ES60'.

       ls_tabname-option = 'EQ'.

       ls_tabname-sign   = 'I'.

       APPEND ls_tabname TO lt_tabname.

       ls_tabname-low = 'ES61'.

       ls_tabname-option = 'EQ'.

       ls_tabname-sign   = 'I'.

       APPEND ls_tabname TO lt_tabname.

     WHEN OTHERS.

   ENDCASE.

   IF changed_by IS NOT INITIAL.

     ls_username-low = changed_by.

     ls_username-option = 'EQ'.

     ls_username-sign  = 'I'.

     APPEND ls_username TO lt_username.

   ENDIF.

 

   SELECT * FROM cdhdr APPENDING TABLE lt_cdhdr

            WHERE username   IN lt_username

            AND   tcode    IN lt_tabname

            and  udate between date_from and date_to

            and  utime between time_from and time_to .

*           AND ( ( udate =  date_from AND utime >= time_from  ) OR udate >  date_from )

*           AND ( ( udate =  date_to AND utime <= time_to ) OR udate <  date_to ).

   IF sy-subrc = 0.

     SELECT * FROM cdpos INTO TABLE lt_cdpos

                         FOR ALL ENTRIES IN lt_cdhdr

                         WHERE changenr = lt_cdhdr-changenr .

     IF sy-subrc = 0.

       LOOP AT lt_cdhdr INTO ls_cdhdr .

         LOOP AT lt_cdpos INTO ls_cdpos WHERE changenr = ls_cdhdr-changenr .

           CALL FUNCTION 'DDIF_FIELDINFO_GET'

             EXPORTING

               tabname        = ls_cdpos-tabname

               fieldname      = ls_cdpos-fname

*             LANGU          = SY-LANGU

             TABLES

               dfies_tab      = lt_tab

*             FIXED_VALUES   =

             EXCEPTIONS

               not_found      = 1

               internal_error = 2

               OTHERS         = 3.

           IF sy-subrc = 0.

             READ TABLE lt_tab INTO ls_tab INDEX 1.

             ls_out-ftext        = ls_tab-fieldtext.

           ENDIF.

         CALL FUNCTION 'BAPI_USER_GET_DETAIL'

           EXPORTING

             username             = ls_cdhdr-username

          IMPORTING

            address              =  ls_name

          TABLES

          return    = lt_return.

IF sy-subrc = 0.

   ls_out-firstname = ls_name-firstname.

   ls_out-lastname  = ls_name-lastname.

ENDIF.

           ls_out-object_type  = object_type.

           ls_out-objectid     = ls_cdhdr-objectid .

           ls_out-changenr     = ls_cdhdr-changenr .

           ls_out-username     = ls_cdhdr-username.

           ls_out-udate        = ls_cdhdr-udate.

           ls_out-utime        = ls_cdhdr-utime.

           ls_out-tcode        = ls_cdhdr-tcode.

           ls_out-tabname      = ls_cdpos-tabname.

           ls_out-chngind      = ls_cdpos-chngind.

           ls_out-fname        = ls_cdpos-fname.

           ls_out-f_old        = ls_cdpos-value_old.

           ls_out-f_new        = ls_cdpos-value_new.

           APPEND ls_out TO it_change_objects.

           CLEAR: ls_cdpos , ls_out, ls_tab, ls_name .

           REFRESH lt_tab.

         ENDLOOP.

         CLEAR ls_cdhdr.

       ENDLOOP.

     ENDIF.

   ENDIF.

 

SORT it_change_objects BY changenr.

 

ENDFUNCTION.

Selecting alias depending on calling system

$
0
0

Hi.

 

Our landscape is like this :

 

external apps --> SAP Gateway HUB (custom code with RFC calls) --> SAP ECC

 

We have developed a global service that will be used by many apps. Depending on the calling system, the user to connect to SAP ECC should be different as in the backend will have different type of access.

 

external app (Germany) --> SAP Gateway HUB (RFC call to ECC with user with german roles) --> SAP ECC

external app (France) --> SAP Gateway HUB (RFC call to ECC with user with france roles) --> SAP ECC

 

I thought that this could be achieved by adding more aliases to the service and then with some logic I should be able to determine the calling system to select later the proper alias.

 

Is this solution possible? Any other way to do it?

 

thanks in advance.

How to add the zservices to a transport.

$
0
0

We have already added the services in /iwfnd/maint_service and choosen the package as tmp, so its stored as a local transport.

 

Now we have the requirement to move the Z* services to QA.

 

Is there a way to add all the Z* services added in /iwfnd/maint_services to a transport? I checked the table IWFND/I_MGDPIM but not sure whether its the only table which has to be transported.

 

Thanks

BOPF: Transient Fields in SADL

$
0
0

Hello,
I’m currently developing a UI5 Application consuming BOPF-Data with the oData service based on SADL.
I wanted to combine data, which is stored in several BOs, into one BO that will be mapped to a single oData entity.
I tried adding transient Fields in an existing BO, but it seems they can’t be consumed by the oData service, as you see at the screenshot.

How can I resolve this problem?

Get Stream method in Batch

$
0
0

Hi Experts

 

How to call get stream method in abatch.

 

example :

 

/sap/opu/odata/sap/ZTEST_SRV/$batch

 

--batch

 

Content-Type: application/http

Content-Transfer-Encoding: binary

 

GET PODownloadSet('4500000314') HTTP/1.1

 

 

--batch

 

Content-Type: application/http

Content-Transfer-Encoding: binary

 

GET PODownloadSet('4500000314') HTTP/1.1

 

 

--batch--

 

2015-10-02_10-48-14.jpg

 

It is working fine, But in this batch i need to call with $value

 

--batch

 

Content-Type: application/http

Content-Transfer-Encoding: binary

 

GET PODownloadSet('4500000314')/$value  HTTP/1.1

 

 

--batch

 

Content-Type: application/http

Content-Transfer-Encoding: binary

 

GET PODownloadSet('4500000314')/$value  HTTP/1.1

 

 

--batch--

 

for this iam getting 202 code but not displaying the files , Please give me suggestions

2015-10-02_10-54-35.jpg

JSON as default format

$
0
0

Is it possible to specify that the default format from SAP Gateway is json and incase the "client" wants it in XML, etc. they can pass the $format parameter.

 

This is to avoid coding $format=json in all the clients (specially UI5 AJAX calls). We are sometimes lazy and forget to do this and thereby ending up with XML which is detected later.

 

Regards,

Parag.

Access to https://sapes1.sapdevcenter.com/webgui for Odata Services.

$
0
0

I am currently using my S-User and Password for logging in the SAP Dev Center and the same credentials to consume the O-Data Services in the third party tools. , however i am not able to access the Administration and configuration T-codes  of O-data Services in the SAP Dev Center due to lack of authorization.

 

Can someone please guide me , how to get sufficient authorizations on SAP Dev Center ?


where can i found the ZIVZ_COA_SRV service code

$
0
0

Hi all,

   i am working on sapui5 development, now i want to using P13nDialog at sap.ui.table.TreeTable (embedded into SmartTable)

   however i can't found the code on the gateway side. do anyone know how to write ZIVZ_COA_SRV service?

     SAPUI5 Explored  here is the demo .

 

 

Thanks,

Billy

'No RFC destination found' error when sending Push notification

$
0
0

Hi All,

 

I am getting an error saying 'No RFC destination found'. Not sure where I am missing.

In my system, GW is installed in my ECC system it self.

I mentioned my Service and collection details correctly.

 

 

I configured my bGRFC destination correctly and mentioned in the settings.

 

 

BgRFC config is also good.

 

 

But I am getting error and my service is not shown in SBGRFCMON.

 

 

Pls help.

 

Thanks

seenu

Backup of Complete OData service in SAP Netweaver Gateway

$
0
0

Hi,

 

Can we talk complete backup of Odata service developed in SAP GATEWAY?

 

Please guide.

 

Thanks.

Pavan G

How SAP is managing Infocus data in Odata Service calls of SAPUI5 Apps

$
0
0

Hi All, We developed all BSP's in stateful manor, We are trying to develop UI5 Apps for all BSP apps, but all of existing API's are working in satateful manor. So we are struggling to reuse these API's. Can anyone tell me how SAP is handling this issue ? Regards, Praveen

Problem with Get Entity in Google Chrome

$
0
0

Hi experts,

 

I created a simple 'Customer' webservice with 'Customer Number' field as the key and it will return customer information.

this is the URL

/sap/opu/odata/sap/TEST_SRV/Customers

 

when i give a customer number #123 as the selection as below

/sap/opu/odata/sap/TEST_SRV/Customers('123')

i can see the result from IE but i got the following weird return below from google chrome.

 

------------------------------------------------------------------------------------------------------------------------------------------

<!DOCTYPE html>

<htmlstyle="height: 100%; margin: 0;">

<head>

<metahttp-equiv="X-UA-Compatible"content="IE=9,10">

<metahttp-equiv="Content-Type"content="text/html; charset=UTF-8">

<metaname="viewport"content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">

<metaname="apple-mobile-web-app-capable"content="yes">

<metaname="apple-mobile-web-app-status-bar-style"content="default">

<title>Logon</title>

<linkrel="shortcut icon"href="/sap/public/bc/ui2/logon/img/favicon.ico"/>

<linkrel="stylesheet"href="/sap/public/bc/ui5_ui5/resources/sap/ui/core/themes/sap_bluecrystal/library.css"/>

<linkrel="stylesheet"href="/sap/public/bc/ui5_ui5/resources/sap/m/themes/sap_bluecrystal/library.css"/>

<style>

* { outline:none; }

input, select, button { font-family:inherit; font-size:inherit; }

 

.sapUiBody { background-image:url("/sap/public/bc/ui2/logon/img/login_background.jpg"); }

.sapUiBody { background-size:100%auto; -webkit-background-size:100%auto; background-attachment:scroll; }

.sapUiSraLoginView { position:absolute; top:0; left:0; right:0; bottom:0; }

.sapUiSraBrandingBar { position:absolute; top:0; left:0; right:0; height:8px; z-index:99; }

.sapUiSraHeader { text-align:center; position:absolute; top:4px; left:0; right:0; background:rgba(0,0,0,0.6); box-shadow:inset0px0.5rem0px0pxrgba(0,0,0,1); color:#ffffff; }

   .sapUiSraHeader.sapUiSraTitle { font-size:1.25em; font-weight:600; padding:4px16px; }

   .sapUiSraHeader.sapUiSraSubTitle { font-size:1em; font-weight:400; padding:4px16px; }

.sapUiSraFooter { position:fixed; bottom:0; left:0; right:0; height:64px; z-index:99; }

.sapUiSraFooterAbsolute.sapUiSraFooter { position:absolute; }

[deleted the rest of the record]

---------------------------------------------------------------------------------------------------------------------------------------------

 

Have you ever got this problem ? and I would like to know if i should do anything to fix this.

 

Thank You !

Viewing all 1745 articles
Browse latest View live