sum problem

qaccess

Registered User.
Local time
Yesterday, 22:05
Joined
Aug 7, 2004
Messages
29
i create a query and i get the next problem:

home and away get values from a table and won is a formula in the query

won: IIf([home]>[away];"1";"0")

home away won
2 1 1
4 4 0
1 3 0
11 2 0

from 0 to 9 the formula works but if home is greater then 9 the formula doesn't work.

What is wrong
 
Home and away are probably Text fields,

in numbers 11 > 2, In strings (text) the first character is checked (1) and 1<2

Greetz
 
solution !!!!

How can i solve this problem. I need to keep the text fields and NO numeric fields, because sometimes a text will be placed in it. Or do I need numeric fields to make formulas

ThanXs
 
You can try doing val([field]) in order to make them numbers, but number fields would be the prefered solution.

Greetz
 
ThanXs

ThanXs The Val command works. But I only get other errors. I will try to figure it out.
 
Probably due to non-number values....

Greetz
 

Users who are viewing this thread

Back
Top Bottom