﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>SQLServerCentral / SQL Server 2005 / Business Intelligence  / IIF or SWITCH Condition to use and how / Latest Posts</title><generator>InstantForum.NET v2.9.0</generator><description>SQLServerCentral</description><link>http://www.sqlservercentral.com/Forums/</link><webMaster>notifications@sqlservercentral.com</webMaster><lastBuildDate>Sun, 19 May 2013 20:32:07 GMT</lastBuildDate><ttl>20</ttl><item><title>RE: IIF or SWITCH Condition to use and how</title><link>http://www.sqlservercentral.com/Forums/Topic1365054-147-1.aspx</link><description>Goto Expressions :iif(fields!country.value="","",&amp;lt;field_name&amp;gt;,&amp;lt;field_name&amp;gt;)</description><pubDate>Fri, 28 Sep 2012 06:07:25 GMT</pubDate><dc:creator>D.DHAMO</dc:creator></item><item><title>RE: IIF or SWITCH Condition to use and how</title><link>http://www.sqlservercentral.com/Forums/Topic1365054-147-1.aspx</link><description>[quote][b]sanju2t (9/27/2012)[/b][hr]Hi, I have a report where countrycode is a paramater and i need to show the date format as dd/MM/yyyy on basis of countrycode. Can someone help me know how can i simplify the statetment for the condition? In Pseudo code:If countrycode in ("AU", "NZ", "IN", "MAL")then     endDate.Format("dd/MM/yyyy")else   endDate.Format("MM/dd/yyyy")end ifI need to write somewhat the same for my report (.rdl) file.ThanksSusheel[/quote]a case statement is your friendcase when countrycode in ("AU", "NZ", "IN", "MAL") then convert(varchar(12),[datecolumn],101)else convert(varchar(12),[datecolumn],103)end*code may take some tweaking</description><pubDate>Fri, 28 Sep 2012 05:58:48 GMT</pubDate><dc:creator>crashdan</dc:creator></item><item><title>IIF or SWITCH Condition to use and how</title><link>http://www.sqlservercentral.com/Forums/Topic1365054-147-1.aspx</link><description>Hi, I have a report where countrycode is a paramater and i need to show the date format as dd/MM/yyyy on basis of countrycode. Can someone help me know how can i simplify the statetment for the condition? In Pseudo code:If countrycode in ("AU", "NZ", "IN", "MAL")then     endDate.Format("dd/MM/yyyy")else   endDate.Format("MM/dd/yyyy")end ifI need to write somewhat the same for my report (.rdl) file.ThanksSusheel</description><pubDate>Thu, 27 Sep 2012 00:46:15 GMT</pubDate><dc:creator>sanju2t</dc:creator></item></channel></rss>