On 7/10/06, Michael Hawksworth <[EMAIL PROTECTED]> wrote:
I have a select statement with a sum on a field that contains an iif statement and it looks as though the iif is truncating the value...&& Example select sum(iif(SomeCondition,ValueX,0)) as TotalValueX from curATable
Sure. That's the SQL preprocessor running the query once and trying to figure out what size the resultant table columns should have - it's why you get single character fields from functions, too. Try it with something like: select sum(iif(SomeCondition,ValueX,00000.000)) as TotalValueX from curATable -- Ted Roche Ted Roche & Associates, LLC http://www.tedroche.com _______________________________________________ Post Messages to: [email protected] Subscription Maintenance: http://leafe.com/mailman/listinfo/profox OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

