Reputation: 3
The script runs okay when just the field name is specified.
But when using IF statement, it gives error that if field not found
.
What is the issue and how to fix it?
"IF(ISNULL(mcdRegion),'',(mcdRegion)) as [Region]"
Upvotes: 0
Views: 551
Reputation: 11
I think for the field name in your 'other' condition you swap out the ()
for []
or leave open since the field doesn't have spaces. So it would be:
IF(ISNULL(mcdRegion),'',[mcdRegion]) as [Region]
or
IF(ISNULL(mcdRegion),'',mcdRegion) as [Region]
Upvotes: 1