Difference Between IF and IFF
Hi Team,
Can say What is the Difference Between the IF and IFF. Where we can use IF and IFF With example?
Regards,
Manikandan N
Can say What is the Difference Between the IF and IFF. Where we can use IF and IFF With example?
Regards,
Manikandan N
- Daniel_mani
- Posts: 11
- Joined: Wed Jan 23, 2019 2:15 pm
Manikandan N,
I'm quoting Gavin Halliday from this post: https://hpccsystems.com/bb/viewtopic.php?f=8&t=1491&p=8422&hilit=IFF#p8422
So, the bottom line is that IFF is used where you need to ensure that only the True response is evaluated if the expression is TRUE and only the False response is evaluated if the expression is FALSE.
Take a look at the referenced thread for the full discussion of that particular real-world problem that using IFF instead of IF solved.
HTH,
Richard
I'm quoting Gavin Halliday from this post: https://hpccsystems.com/bb/viewtopic.php?f=8&t=1491&p=8422&hilit=IFF#p8422
... IF() only tries to ensure that only the correct branch of the IF() is executed if the type of the results is an action or a dataset. For scalars (and rows) both branches may be executed.
To ensure that the other branch isn't executed you can use IFF(). ...
So, the bottom line is that IFF is used where you need to ensure that only the True response is evaluated if the expression is TRUE and only the False response is evaluated if the expression is FALSE.
Take a look at the referenced thread for the full discussion of that particular real-world problem that using IFF instead of IF solved.
HTH,
Richard
- rtaylor
- Community Advisory Board Member
- Posts: 1619
- Joined: Wed Oct 26, 2011 7:40 pm
3 posts
• Page 1 of 1
Who is online
Users browsing this forum: Bing [Bot] and 1 guest