Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello Qlik Community,
Situation:
In our company, I have to rebuild the logic of a legacy SAP report in Qlik Script.
Using the SAP Report Connector in legacy mode is no option.
Part of the task is to read data from the SAP CO module. The output structure is 'KKBC'.
Inside of SAP, the standard SAP function module (FM) named 'K_KKB_CO_OBJECT_READ' is used for this.
Since this FM is not capable of being used via Remote Function Call (RFC), i.e. via Qlik SAP BAPI connector, I have built a custom RFC FM named 'YQLIK_K_KKB_CO_OBJECT_READ' that just passes the same parameters to the original SAP function module.
A lot of the inputs of the FM are not simple parameters like characters, integers and so on, but RANGE TABLES (screenshot 1):
Screenshot 1:
I managed to build according table types (screenshot 2) and structures (screenshot 3) for each of these range tables inside of my RFC FM:
Screenshot 2:
Screenshot 3: Example of structure of table type 'YQLIK_K_KKB_CO_OBJECT_READ'
In the original ABAP code of the SAP report, a range table can be filled like this (screenshot 4):
Screenshot 4:
So far, so good.
Problem:
I don't know how to transist this ABAP code into OpenSQL when calling my RFC FM with the SAP BAPI connector from Qlik Sense!
Using the wizard for tables in Qlik Sense gives me the following window (screenshot 5):
Screenshot 5:
What do I have to enter here to rebuild the logic of ABAP shown in screenshot 4 above???
If I enter this (screenshot 6), the result looks like this (screenshot 7):
Screenshot 6:
Screenshot 7:
The result of the RFC FM call is (of course) empty.
The 'WHERE' statement above that the wizard built does neither use 'AND' nor 'OR'.
Is this correct?!?
What I have already learnt is that before Qlik SAP Connector version 6.6, the syntax for this looked a lot different as shown e.g. here:
http://www.minipps.com/Blog/calling-sap-function-from-qlikview-blog.aspx
But since this requires legacy mode on Qlik Sense (which is not desired in our Qlik Sense server environment), I cannot go down that road.
Any help would be highly appreciated!
Best regards,
The Fitness Captain
Hello,
I have similar situation.
Qlik connector can't access to function parameters with table type. (multiple lines)
I guess there is a need of development for the connector.
Hello Coskun Istanbulluoglu,
just wanted to say that when the SAP ABAP code looks something like this (picture),
then your "WHERE" statement in Qlik Script must look like this:
T_BEKNZ = TABLEROW('I', 'EQ', 'S', '') |
T_BEKNZ = TABLEROW('I', 'EQ', 'H', '')
I tested it and it works.
Regarding your problem, I suggest that you make sure that in your RFC function module, your (custom?) paramenter "IT_CHARG" is exactly implemented like the other parameters that are accessible from the Qlik SAP BAPI connector.
Can you please post screenshots showing your RFC function module in transaction SE37?
Best regards,
The Fitness Captain
Hi Coskun,
I have developed the SAP BAPI Connector for Sense and am curious what the definition of IT_CHARG parameter looks like? The Connector queries both IMPORTS (single row input) and TABLES (multi rows). From your SE37 screenshot it hints that it's not a TABLES (as it's shown under import parameters and not tables). Maybe it's an IMPORT with type TABLE?
Regards,
// Thomas Örnmarker
SAP Connectors Developer
Dear Thomas,
Thank you for help, and I am sorry for late answer.
Here is the the information you asked: CHAR 10
Dear Thomas,
Do you think we can find a solution for my problem?
I guess, I need to ask help from Abap Developer.
Qlik Bapi connector need some development for this case, am I right?
Hi Coskunist,
You are right that we currently don't support imports of table type. This is something that I want to add for next release. Currently there are support for using tables if they are defined as TABLES (allows for both IMPORT and EXPORT).
Regards,
// Thomas