1. Martin Kaltenböck
  2. PowerBuilder
  3. Wednesday, 14 June 2017 10:50 AM UTC

Hello,

I'm using Powerbuilder 12.1 Classic Build 6639, Windows 7 64

In my application I do a call to a webservice - function 'rkdb'. (I use the .NET WS engine)

The rkdb function can do certain things depending on the request-parameters given.

All function calls work well, except one that returns NULL.

I used Fiddler and even set up a SoapUI-Project to test the function with the same parameters and I can see that a valid SOAP-Response is returned containing all values expected.

So the problem must be at the PB side.

The returned object consists of a couple of nested objects.
One of the objects is defined as follows:







The object created in PB by the WS-proxy shows like this:

type variables
any ws_Any[]
end variables

I think that this could be the problem, because I found related infos in another thread:

"No any datatype as WS Result (by Chris Pollach)":
https://archive.sap.com/discussions/thread/3904173

There is stated, that powerbuilder WS-Clients can only deal with standard C-types.

Am I right, is this the cause for the problem and how to solve this?

I'm sure I cannot talk to the webservice vendor to change this.

Here's the link to the WSDL-File:

https://finanzonline.bmf.gv.at/fonws/ws/regKasseService.wsdl

Here's the code for calling the webservice:

soapconnection lsc_fon

rkdbservice ln_rkdbservice

rkdbrequest ln_request
rkdbresponse ln_response

belegpruefung ln_belegpruefung

ls_proxy = "rkdbservice"
ls_function = "rkdb"

lsc_fon = create soapconnection


ll_rc = lsc_fon.CreateInstance(ln_rkdbservice, ls_proxy)

try

ln_request = create rkdbrequest
ln_request.tid = as_tid
ln_request.benid = as_benid
ln_request.id = as_session_id
ln_request.erzwinge_asynchron = ab_erzwinge_asynchron
ln_request.erzwinge_asynchronspecified = true

ln_request.art_uebermittlung = 0

ln_belegpruefung = create belegpruefung
ln_belegpruefung.satznr = as_satznr
ln_belegpruefung.kundeninfo = left(as_kundeninfo, 50)
ln_belegpruefung.beleg = as_beleg

ln_request.ws_rkdb = create rkdb
ln_request.ws_rkdb.fastnr = gs_null

ln_request.ws_rkdb.ts_erstellung = f_today_now()
ln_request.ws_rkdb.paket_nr = "1"
ln_request.ws_rkdb.ws_belegpruefung = ln_belegpruefung
ln_response = ln_rkdbservice.rkdb(ln_request)

ln_response = ln_rkdbservice.rkdb(ln_request)

// ln_response is NULL ???

catch ...


Thank you for any help!

Martin

PS: Posted this question some days ago to SAP answers site but go no answer yet. I don't think that the SAP site is the current place for Powerbuilder questions, so I posted the question here again - if I'm wrong, sorry for cross posting.

 

Chris Pollach Accepted Answer Pending Moderation
  1. Wednesday, 14 June 2017 16:56 PM UTC
  2. PowerBuilder
  3. # 1

Hi Martin;

  Yes, PB's Web Service handling requires:

1) WS only return "Standard Data Types" as in "C" (or PB for that matter).

2) The returned values must be in the form of an ANSI result set.

3) The result set must be in the form of a two dimensional array.

    (like you would see in any DataWindow's buffers)

Regards ... Chris

Comment
  1. Martin Kaltenböck
  2. Wednesday, 14 June 2017 19:43 PM UTC
Thank you Chris, that's what I feared.



Is there any chance to work around?



Last alternative, maybe, is to code the WS call in another language and call that helper program from PB ...



 

  1. Helpful
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.
We use cookies which are necessary for the proper functioning of our websites. We also use cookies to analyze our traffic, improve your experience and provide social media features. If you continue to use this site, you consent to our use of cookies.