on 05-19-2015 1:39 PM
Hi.
I have created 2 input parameters as type date for the start and end dates. I want to create a calculated column to calculate the days between the dates selected. I have done it on 2 separate ways but get different errors on both.
1st method: daysbetween('$$p_StartDate$$', '$$p_EndDate$$') goves error that my parameters are of type string, which it is not.
2nd method: daysbetween(daydate('$$p_StartDate$$'), daydate('$$p_EndDate$$')) - gives a Column Store error 6931 attribute is not a date or syntax error.
Could you please advice what I am doing wrong, we are on HANA rev 91.
Thanks.
Koos.
Hi Koos,
Try using the below syntax.
daysbetween(date($$start_date$$),date($$end_date$$))/365
Regards,
Venkat N.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
More info would be nice...here's how. Also I could have give more instead of guiding line for misunderstanding Sorry. Lets do it with screenshots...Venkateswarlu Nandimandalam example...
I have example Analytic view with 2 Imput parameters
Hana rev 95
Hi Dubravko.
I am doing exactly the same with different outcome.
My Parameters:
and calculation check
and then I saw that when I double click on the parameter to add it to formula it puts a single quotation mark in front and back. So as soon as I remove it the formula is working.
I do not understand why but thanks it is working.
Try $$p_EndDate$$ - $$p_StartDate$$
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
94 | |
11 | |
11 | |
10 | |
9 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.