Calculated Query???

  • Thread starter Thread starter Alex
  • Start date Start date
A

Alex

I have two amount fields in a table e.g.

Amount 1 Amount 2
10 10
20 50
30 30
40 60

I want to be able to run a query that displays only those
records where Amount 2 is different to Amount 1. From the
example above I would expect to see the result;

Amount 2
50
60

Is this possible?
 
one way might be to build a new column and put something like...

Diff: [Amount1]-[Amount2]


Then in the criteria for that column, put...


<>0




Hope that helps,

Rick B


I have two amount fields in a table e.g.

Amount 1 Amount 2
10 10
20 50
30 30
40 60

I want to be able to run a query that displays only those
records where Amount 2 is different to Amount 1. From the
example above I would expect to see the result;

Amount 2
50
60

Is this possible?
 
I have not tested it, but I think you could also simply put the following
criteria under Amount 1...


<>[Amount2]




I have two amount fields in a table e.g.

Amount 1 Amount 2
10 10
20 50
30 30
40 60

I want to be able to run a query that displays only those
records where Amount 2 is different to Amount 1. From the
example above I would expect to see the result;

Amount 2
50
60

Is this possible?
 
A Query with the SQL String:

SELECT [Amount 2]
FROM [YourTable]
WHERE [Amount 2] <> [Amount 1]

should do.

HTH
Van T. Dinh
MVP (Access)
 
Back
Top