General information
Category:
Databases,Tables, Views, Indexing and SQL syntax
To ALL,
I have a similar question, and am hoping to continue this thread... (years later and using VFP8)
I have a table where one of the fields accepts null values (lets call it nullfield1 and it is of type double with the null flag checked)
The following works just fine:
select field1, sum(nullfield1) from sometable group by 1
I also know that I can perform the following:
? .NULL. * 2
.NULL.
So... why can't I do this -
select field1, sum(nullfield1) * 2 as nullfield2 from sometable group by 1
***Error Message*** field nullfield2 does not accept NULL values
It seems reasonable, and I really have a need to solve this type of problem. Using NVL doesn't seem to work, because I really want to see both null values and not null values in the resultant select after they have been multiplied by 2 (or some other valid function that uses null values).
Thanks
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only