Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 decode

Author  Topic 

sqlclarify
Yak Posting Veteran

56 Posts

Posted - 2009-03-08 : 16:30:30
Hello,

I am confused about how decode works? Is it like the C++ version of the if-elseif statement that is, once one of the conditions evaluates to true does it exit the decode statement or does it continue evaluating the other conditions in it too? (in cases where there are more than one conditions)

Similarly, the case expression, when we have more than one condition does it check the other conditions too even when one of them evaluates to true?

sodeep
Master Smack Fu Yak Hacker

7174 Posts

Posted - 2009-03-08 : 16:35:03
Can you clarify with some examples?
Go to Top of Page
   

- Advertisement -