Skip to Content
0

HANA SQL Issues

Apr 14, 2017 at 12:57 PM

112

avatar image

Hi All

I'm trying to implement the same logic in HANA

https://stackoverflow.com/questions/43405295/time-dependent-queries

1) When i try the sql its issuing an error message saying that e1 startdate is not in group by clause -- i'm talking about the left outer join sql query

2) How do i implement this in graphical calculation view with non equi joins like e.startdate > e1.startdate etc

Thanks in Adv

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Mateusz Bialy Apr 14, 2017 at 03:25 PM
-1

Hello,

You should use script view instead of graphic view
Example tutorial for SQL window functions:

https://www.youtube.com/watch?v=e4TpAIY97hg

https://blogs.sap.com/2014/10/04/window-function-vs-self-join-in-sap-hana/


Regards,
Mateusz.
Show 2 Share
10 |10000 characters needed characters left characters exceeded

Maybe one additional comment to that answer. The advice to use a scripted calculation view instead of a graphical calculation view is not really correct anymore, because scripted calculation views are already outdated since some support packages ago.

If a scripted part is necessary in a graphical calculation view - for instance the usage of the window LEAD function for this requirement - table functions have to be used. Table functions are valid data sources for graphical calc. views since HANA 1.0 SPS09.

Best Regards,
Florian

1

Florian, you are right. My answer is more appropriate to SAP BW on HANA where you need another transport path for table functions.

Best regards,
Mateusz.

0