Tristan Leask wrote:
> Afternoon all,
>
> I have got a strange one here.  I have written a SELECT statement which
> is something similar to....
>
> SELECT f1, f2, max(f5,f6) as test FROM t1......
>
> This looks ok to me, however when I try to run it, foxpro doesn't like
> the fact that I am using the MAX() function.  Apparently when MAX() is
> used in a SELECT statement it wants to calculate the maximum of the
> specified column.  Thus can you not use MAX() to calculate the maximum
> of some fields in a row, E.g. MAX(f1, f2, f3, f4)?
>   
I havn't tried it but what about

SELECT f1, f2, iif(f5>f6,f5,f6) as test FROM t1.....

Peter





_______________________________________________
Post Messages to: ProFox@leafe.com
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: http://leafe.com/archives/byMID/profox/[EMAIL PROTECTED]
** 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.

Reply via email to