>SELECT AreaFK, StationFK, CrewFK, ; >> MIN(EVL(nextminor,{^9999/12/31})) AS NextMinor, ; >> MIN(EVL(nextmajor,{^9999/12/31})) AS NextMajor, ; >> .F. AS doMinGroup, .F. AS doMajGroup ; >> FROM premaint GROUP BY AreaFK, StationFK, CrewFK ; >> INTO TABLE maintdue
NVL()
instead of EVL()
. I tested NVL()
and found that for an empty table.datefield it always returns the empty table.datefield and not the constant date supplied in the second parameter.