Hi.My name is Naomy and I’m an intern in SAP. Recently, I have used TPC-H benchmark(2.17.1) to run some tests on HANA database.Although all of the queries are written in the SQL-92 language, some queries still need to be rectified so that they can be executed on HANA.But the syntax differences don’t necessary make SAP HANA SQL92 incompatible as the SQL standard leaves many aspects to the system implementation.


The fourth query ,for example, uses ‘interval‘ to calculate a period of time.

Capture.PNG

But it couldn’t be executed on HANA .It seems that HANA SQL doesn’t support ‘Interval’ as a reserved word.

Capture.PNG

So I used the ADD_MONTHS function to replace ‘Interval’.

Capture.PNG

Likewise,when I met the queries using ‘interval n day‘ or ‘interval n year‘, I used ADD_DAYS function or ADD_YEARS function to replace the part of queries.


What’s more, SAP HANA doesn’t support ‘AS‘ to set alias in parentheses.

The 13th query, for instance, couldn’t be executed in HANA.

Capture.PNG

So, I rectified it as shown in the following picture and it works.

Capture.PNG

Above information is what I have learned when I used TPC-H benchmark queries in my HANA project.I hope it helps fellows who meet //http://scn.sap.com/#//the //same problem.//http://scn.sap.com/#

To report this post you need to login first.

6 Comments

You must be Logged on to comment or reply to a post.

    1. Lars Breddemann

      Hi Remi,

      despite the catchy title this blog was about the syntactic differences of SQL-92 and the SAP HANA implementation – not about the benchmark results.

      The questions you posted sound interesting. Maybe you open a discussion thread and describe a bit more in detail what you want to know about.

      – Lars

      (0) 
    2. Naomy Xu Post author

      Hi Remi,

      I haven’t measure the different partitionning strategy on large tables yet,but I ‘m going to do it this month.I hope I can provide some valuable results later.

      BTW,does the ‘flat files’ you mention is the data generated by TPC-H DBGEN?

      (0) 
      1. Remi ASTIER

        Yes, the “flat files” are the files generated by this program that contain the data.

        TPC-H results is a sensitive topic, I suggest that we align internally before you publish anything externally.

        (0) 
  1. Scott Hunter

    Do you have the set of scripts and data that ran against HANA in a package I might download?  I am anxious to find a way to load test our HANA appliances.

    Thanks!

    (0) 
    1. Naomy Xu Post author

      Hi Scott,

      I attached the scripts I used in my project to this blog, maybe you can refer to it.

      Hope it helps. 🙂

      (0) 

Leave a Reply