Quantcast
Channel: SCN : Unanswered Discussions - SAP HANA and In-Memory Computing
Viewing all articles
Browse latest Browse all 4343

SAP HANA scripted Calc View syntax

$
0
0

Hi HANA experts,

 

My scenario is as follows:

 

Currently, I have a calculated column with the following logic:

 

IF ( now() > daydate(string(component(now(),1))+'1010'), daydate(string(component(now(),1))+'1010'),

IF ( now() > daydate(string(component(now(),1))+'0710'), daydate(string(component(now(),1))+'0710'),

IF ( now() > daydate(string(component(now(),1))+'0410'), daydate(string(component(now(),1))+'0410'),

IF ( now() > daydate(string(component(now(),1))+'0110'), daydate(string(component(now(),1))+'0110'),

daydate(string(component(now(),1)-1)+'1010') ) ) ) )

 

I want to create a scripted calc view with the same such logic in a column.

 

What is the proper syntax to do so?

 

I have already tried using case statements and if statements using common sql syntax but can't seem to get it to work

 

Thanks in advance!

John


Viewing all articles
Browse latest Browse all 4343

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>