This field is required.
Only these extensions are allowed(.jpg, .JPG, .jpeg, .JPEG, .gif, .GIF, .png, .PNG)
Tags cannot contain the characters ' /, \\, #, ?, or ; >,< '
Only these extensions are allowed(.zip,.ZIP,.pdf,.PDF,.qvf,.QVF,.qvw,.QVW)
Discussion Board for collaboration related to QlikView App Development.
Hello qlikview experts,
i need to understand the if condition in qlikview.
In my scenario I am using the if condition in my script level.
if( FLAG ='X', [Earliest DATE], [END DATE]) as plan Date
[Earliest DATE] = 1/1/2015
[END DATE] = 12/1/2014
here the data modeling is done such a way that flag = 'X' exists for both the feilds [Earliest DATE] & [END DATE].
As per my understanding I should get answer as 1/1/2015 which is in [Earliest DATE] feild as FLAG ='X' holds the condition true.
But in my condition it is taking value for both if and else condition.
for eg. both 1/1/2015 & 12/1/2014 in the list box which gives me error in further calculations.
If the condition is true it should take the only the first value. I have tried the same condition with other inline table it is giving me proper answer.
I am confused where I am wrong.
Just wondering how feasible it is to upload a sample qvw file so that we can work on it quickly.
Thanks for the instant answer.
But could not attach any kind of sample file from the office due to the security constraints.
I have got the root cause of the issue as it is creating the two rows and taking both the values.
I can only confirm that your understanding of the if() function is correct.
What is going on in your situation - can't tell without an example. You don't need to upload the actual application, just create simple example where you can reproduce the issue.
May be your Flag value is not being reset properly in your script..As far as the if condition is concerned, it looks fine
if( '$(FLAG)' ='X', [Earliest DATE], [END DATE]) as plan Date
Could not understand 'the data modeling is done such a way that flag = 'X' exists for both the feilds [Earliest DATE] & [END DATE]' . Can you elaborate this?
So, I was getting the unexpected result.
Great to know that your problem is resolved.Please close the thread with your resolution and marking the correct answer