Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

How ABAP report can recognize if SAP HANA is underlying database?

Former Member
0 Kudos

HI,

I remember that some FM do the job but unfortunately I forgot where I sow it and its name

Can any anyone recall its name? Or maybe there is another way to recognize SAP HANA inside ABAP report?

Regards

Pawel 

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi,

on the one hand side, in all releases there is the system field sy-db which can be used to check for the value 'HDB'.

In ABAP 7.4, there is in addition the class CL_DB_SYS (SAP_BASIS) which can be also used for detecting SAP HANA. This has the advantage to benefit from where-used lists for detecting the coding relying on such a distinction.

Regards,

Eric

4 REPLIES 4

Former Member
0 Kudos

Hi,

on the one hand side, in all releases there is the system field sy-db which can be used to check for the value 'HDB'.

In ABAP 7.4, there is in addition the class CL_DB_SYS (SAP_BASIS) which can be also used for detecting SAP HANA. This has the advantage to benefit from where-used lists for detecting the coding relying on such a distinction.

Regards,

Eric

0 Kudos

Thanks a lot Eric,

A you can see, sometimes the head flying in the sky can overlook the solution lying just a step away (sy-dbsys)

Regards

Paweł

0 Kudos

Exactly, SY-DBSYS does the trick.

One can use RFC_SYSTEM_INFO to check the DB via RFC. The value we are interested in is RFCSI_EXPORT-RFCDBSYS = HDB.

cheers Otto

christian_seitel
Participant
0 Kudos

Maybe you are interested in SAP HANA as the underlying database because you want to use one of its features. Then the class CL_ABAP_DBFEATURES should be used to check whether a particular feature is available or not.

Regards, Christian