Make Nulls = 0

  • Thread starter Thread starter Eric
  • Start date Start date
E

Eric

Hi,

I want to make my query to decide if the field is Null or
Empty then I want to place a zero to take it's place. I
scarched on IIF's and can't seem to get it right. The SQL
statement below is without the IIF:

SELECT AnalysisEPSP.TestGroupID,
AnalysisEPSP.SampleGroupID, Sum([BeadExpansionScore]+
[BeadInBlanketScore]+[BlanketMarksScore]+[ColorScore]+
[colorVariationScore]+[EdgeBuildupScore]+[GapScore]+
[GhostingScore]+[HeightScore]+[InkOutScore]+[RegisterScore]
+[ScalingScore]+[SpecklingScore]+[WetInkScore]+
[OtherScore]) AS Totals
FROM AnalysisEPSP
GROUP BY AnalysisEPSP.TestGroupID,
AnalysisEPSP.SampleGroupID;
 
look at the Nz function in help.

NZ([SomeFieldName],0)

would return the vaule of your field (unless null). If null, it would
return 0.

Rick B
 
Back
Top