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.
Author |
Topic |
Limuh
Yak Posting Veteran
94 Posts |
Posted - 2009-07-21 : 01:08:43
|
hello i want to make an expression. The scenario is if there are blank column in the database i want to show "None" in the report. i decided to do it by report expression rather than doing it in the Stored procedure.. is it correct? =IIf((Fields!GP.Value) = Nothing ,"","None" & Fields!GP.Value) Thank you. |
|
bsivel
Starting Member
8 Posts |
Posted - 2009-07-23 : 12:22:08
|
1. Try this...=IIf(Fields!GP.Value = Nothing ,"None",Fields!GP.Value)2. You may have to also check for a zero length string like the following:=IIf(Fields!GP.Value = Nothing ,"None", IIf(Fields!GP.Value = "","None",Fields!GP.Value)3. I recommend setting this in the stored procedure or query similar to the following:Select Case when len(ltrim(rtrim(isnull(GP,''))) = 0 then 'None' else GP End as GPFrom ....Brian Sivel |
|
|
|
|
|