I have an application, which is broken with respect to recording usage. If the emergency stop is pressed, the application still records the usage, but because it interfaces with a scale, and the weight of the scale usually contains a bucket, the usage recorded will be -2 to -5 (if the bucket is removed). Since users can press the stop several times a day, there are plenty of negative usage values in the DB.
I would like to only SELECT when the weight is > 0. This is easy with a "regular" SELECT statement. However, I am trying to use the SUM feature, to give the report a summary, and currently the report takes into account the negative values. How do I only SELECT based on the weights > 0 in my SUM??
TIA... Bruce Garlock
bruceg@tiac.net
I would like to only SELECT when the weight is > 0. This is easy with a "regular" SELECT statement. However, I am trying to use the SUM feature, to give the report a summary, and currently the report takes into account the negative values. How do I only SELECT based on the weights > 0 in my SUM??
TIA... Bruce Garlock
bruceg@tiac.net