Hi,
I am attempting to extract the sum of the absolute values of table1.variable1 in MS Query.
i.e. i would like to this...
SELECT (Sum(ABS(table1.variable1)))
FROM table1
WHERE table1.variable1 <=0
but there is no built-in function that returns absolute numbers from a list of records. I also thought about doing this...
SELECT (Sum((table1.variable1*table1.variable1)^0.5))
FROM table1
WHERE table1.variable1 <=0
I was sure that MS Query had powers in its list of acceptable arithmetic functions, but when I run that the error message 'Invalid operator for datatype op: BOOLEAN XOR type: FLOAT' . Obviously clicking on 'Help' is totally useless!
Can anyone help....thanks
I am attempting to extract the sum of the absolute values of table1.variable1 in MS Query.
i.e. i would like to this...
SELECT (Sum(ABS(table1.variable1)))
FROM table1
WHERE table1.variable1 <=0
but there is no built-in function that returns absolute numbers from a list of records. I also thought about doing this...
SELECT (Sum((table1.variable1*table1.variable1)^0.5))
FROM table1
WHERE table1.variable1 <=0
I was sure that MS Query had powers in its list of acceptable arithmetic functions, but when I run that the error message 'Invalid operator for datatype op: BOOLEAN XOR type: FLOAT' . Obviously clicking on 'Help' is totally useless!
Can anyone help....thanks