How to schedule SAP HANA procedures by using SAP BW Process Chains
Recently, i got a request from one of my customer asking to schedule SAP HANA procedures. We discussed a couple of alternatives. One is to use Linux cron jobs , other is similar, windows task scheduler and also XS job scheduler, but we need something part of our BW world. Then i decided to create a simple link between SAP BW and HANA procedures. To do that i used AMDP approach. You may find further information about amdp from here
You need to install ABAP for Eclipse plugin to your SAP HANA Studio in order to start development. This can be found here. I recommend to check this document also to get familiar to abate development for hana.
1. First create an ABAP project ( if you don’t know how to create it, refer to this link ) , then add an abap class.
2. This class will be our proxy between ABAP layer and HANA DB procedure. As you can see there is an input parameter for the ZBW_MTRC_AMDP_SP_CALL procedure.
3. In order to activate ABAP class, you need to create HANA SP first. Our HANA SP is simple, just the sp that will be called from ABAP layer. Here my intension is to keep it simple as it is possible, you my add dynamic schema name, output parameters to your sp that will return back to ABAP layer.
4. After your AMDP ABAP Class is activated you can also check it from SE24 as read only. You can not edit AMDP classed from SAP GUI.
5. Then create a simple program from SE38 that will be used in process chains with variants later on. Again you can extend scope and functionalities of program according to your requirements.
6. Create a variant by running the program.
7. then create a BW process chain and add ABAP program from general services.
8. Then specify program and its variant.
9. Schedule your process chain as desired!.
I hope it helps in your SAP HANA Journey.