Problem Creating a calculated field access 2010

Jackrees

New member
Local time
Today, 09:11
Joined
Feb 22, 2013
Messages
5
I have table of transaction data, I want to count the number of successful customer transactions but the table includes cancelled transactions with anegative value.

I was therefore looking to create a new calculated field for customer count which report either "1" or"-1" depending on if the price is positive or negative. The idea being a count of this would give the customer count. The expression I am using is:

[FONT=&quot]IIf([Price]>=0, 1, -1)[/FONT]

The problem is it I get an error message saying "The calulated field cannot be created" "verify that expressio "[FONT=&quot]IIf([Price]>=0, 1, -1)" includes fields that exist in the current table" [/FONT]


If anyone could advise on this it would be much appreciated.

Thanks
Jack
 
You should not store calculated fields in a table, but calculate the results when required in yor reporsts or forms. Tables are for storing data not entering or looking at it which is what Forms and Reports are for.

Brian
 

Users who are viewing this thread

Back
Top Bottom