14.01.2020 Views

ABAP_to_the_Future

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Other Modifications to ABAP for SAP HANA 15.5

NativeSQL is missing no longer, and now you can achieve the same thing using

OpenSQL.

15.5.3 Changes to Database SELECT Coding

There are various changes you need to make to the SELECT statements you code,

to make sure you don’t get any unpleasant surprises in your current custom programs

when you switch to an SAP HANA database.

First, there is some good news: When you move to an SAP HANA database, virtually

all existing code you’ve written toaccess database tables will still work, and

a lot of it will run a lot faster without you lifting a finger. Moreover, as time goes

by SAP keeps making improvements under the hood (e.g., in SAP NetWeaver 7.4

SP 5, the performance in an SAP HANA database of FOR ALL ENTRIES and SELECT

SINGLE was improved without needing any code changes at all).

However, life is not all beer and chocolate. If your SELECT statement is badly written

in the first place, then moving to SAP HANA will most likely make the performance

a billion times worse. This is the opposite of what you might expect. Two

examples of badly-written SELECT statements are those that select lots of columns

you do not need and nested SELECT statements. Those are bad practices that have

a negative impact on any database system but have a really bad impact on an SAP

HANA database. In addition, in some rare situations you may find your existing

programs behaving very strangely after the switch to SAP HANA, coming up with

all sorts of incorrect results.

For this reason, you should know about some Code Inspector checks that will

help you find and fix such problems. An important thing to note is that you can

run these checks before you migrate to SAP HANA. In fact, as soon as those

checks are available in yo ur system, run them anyway and make the recommended

fixes, even if yo u’re not planning to move to SAP HANA anytime soon

(or ever). The benefits of such correction s are greatest for organizations that are

transitioning to SAP HANA, but the changes will make your programs more

robust no matter what database system you’re using. The checks discussed can be

switched on by going into the Code Insp ector transaction (SCI) when you’re setting

up your check variant (i.e., making a list of possible errors or performance

killers in your code that you want to check for).

697

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!