cancel
Showing results for 
Search instead for 
Did you mean: 

Virtual procedure calling from AMDP

0 Kudos

Hi gurus! We are facing serious troubles trying to call a virtual procedure (SDA) through an AMDP procedure. We don´t have problems executing local procedures. There is an error when we use "EXEC" (you can´t call virtual procedures whit EXEC), but using only a CALL <PROCEDURE> simply does nothing, without errors or warnings. We are on HANA 2.00.033, BW 7.4 SP16.

The virtual procedure is the EXEC function of SDA FILE_ADAPTER:

CREATE VIRTUAL PROCEDURE "_SYS_BIC"."FA_EXEC" (IN PATH NVARCHAR(1024), IN PARAM NVARCHAR(1024), IN FLAG INTEGER, OUT param_3 TABLE (RESULT NVARCHAR(1024))) 
CONFIGURATION '{
  "__DP_UNIQUE_NAME__": "EXEC",
  "__DP_HAS_NESTED_PARAMETERS__": false,
  "__DP_USER_DEFINED_PROPERTIES__": {},
  "__DP_INPUT_PARAMETER_PROPERTIES_": [],
  "__DP_RETURN_PARAMETER_PROPERTIES_": [],
  "__DP_VIRTUAL_PROCEDURE__": true,
  "__DP_HAS_INTERNAL_OUTPUT_PARMETER__": false,
  "__DP_DEFAULT_OUTPUT_PARAMETER_INDEX__": 0
}' AT "ZFILEADAP"

The AMDP class:

CLASS zbw_call_st DEFINITION
 PUBLIC
 FINAL
 CREATE PUBLIC.
PUBLIC SECTION.
*Marker interface for Database Procedures
 INTERFACES: if_amdp_marker_hdb.


* Method Definition
 CLASS-METHODS NAD_GET_DATA.


PROTECTED SECTION.
PRIVATE SECTION.
ENDCLASS.


CLASS zbw_call_st IMPLEMENTATION.


method NAD_GET_DATA by database procedure
for HDB
language sqlscript.


call "_SYS_BIC"."FA_EXEC"('D:\Data\fileadapter\scripts\nad_dataload.bat','PARAM',3,?);


endmethod.


ENDCLASS.

It couldn´t be easier...

Are there some restriction about calling virtual procedures from AMDP? Are there some other option for calling virtual procedure from ABAP?

Some insider advice would be great!!! Thanks!!! jasmin.gruschke jens.weiler

Kind regards and thanks in advance!

Accepted Solutions (1)

Accepted Solutions (1)

0 Kudos

Imposible to make this work. Work-around by using ADBC old-fashioned functionality 🙂

Answers (0)