This will work in V6. V7's MAX function lets you compare up to four different values, though, not just two in V6.
Mike /b[/quote]What a very interesting approach Mike! I like that.
When I have had similar situations it has usually been that one or other field would be populated so I have tended to use an IF statement. Something like;
Another way, if both possible fields are numeric but only one will have a value greater than zero (assuming fields will not be negative) is simply to add the fields together to get a final result.
At all depends ...
I like Mike's idea though. I can see interesting uses for it.
[size="1"][ November 11, 2003, 01:45 PM: Message edited by: Grant Perkins ][/size]
Glad to be of help, and I will also mention that Monarch V7 enhanced the MAX function, such that up to four different fields/values can now be evaluated in one calculated field (used to be only two different values could be compared using MAX, or MIN, for that matter).
BTW, another good question came up on the forum, for which [url="http://mails.datawatch.com/cgi-bin/ultimatebb.cgi?ubb=get_topic;f=1;t=000343"]Monarch V7's new STRIP function[/url] solved nicely (see also the new Nov. Monarch Report newsletter).
See the full list of new and improved V7 functions in the upgrade brochure: [url="http://www.datawatch.com/pdf/products/monarch/Monarch_V7_web_brochure.pdf"]http://www.datawatch.com/pdf/products/monarch/Monarch_V7_web_brochure.pdf[/url]
[size="1"][ May 19, 2006, 12:31 PM: Message edited by: Todd Niemi ][/size]