need help with simple criteria in query

S

SylvieB

Hello all
On a report, the field "order value" needs to be expressed in Million and
show only records >2 millions dollars. On the form, it is expressed in
thousand. .
So far, in the query, I have under the field "order value", criteria is:
=2000 and (order value \ 1000) but it does not work. I 'm not sure how to
write a criteria to convert the numbers from thousand to million.
Any help would be greatly appreciated. In advance, thank you.
Sylvie
 
S

SylvieB

Hello Dale
thanks so much for your response. I'm a bit confused with the first part of
your answer. You write "in the first column, give the computer column a new
column name", where do you do that? Forgive my ignorance, but I'm trying to
understand.
is it in the expression builder? thanks

Dale_Fye via AccessMonster.com said:
Your query might look something like:

SELECT Field1, Field2, [Order Value]/1000 as "Order Value ($M)"
FROM yourTable
WHERE [Order Value] >= 2000

To do this, add the [Order Value] field to the query grid twice. In the
first column, give the computed column a new column name, and divide by 1000

Order Value ($M): [Order Value] / 1000

Then, in the next [Order Value] column, add the criteria >= 2000 and uncheck
the box to display the field.

HTH

Hello all
On a report, the field "order value" needs to be expressed in Million and
show only records >2 millions dollars. On the form, it is expressed in
thousand. .
So far, in the query, I have under the field "order value", criteria is:
write a criteria to convert the numbers from thousand to million.
Any help would be greatly appreciated. In advance, thank you.
Sylvie

--
HTH

Dale Fye

Message posted via AccessMonster.com
 
S

SylvieB

I finally got it. I got confused with the field. Ten thousands thanks for
your help. I really appreciate it. Merci :)

Dale_Fye via AccessMonster.com said:
When you open your query in design view, you get the tables section at the
top, and a grid at the bottom that when you add some fields might look like:

Field: Field1 Order Value ($M):[Order Value]/1000 [Order Value]
Table: yourTable yourTable
yourTable
Sort:
Show: Yes Yes No
Criteria:


To avoid word wrap, I've left off one of the extra columns, but the important
part is that you get the computed column formula and the criteria correct for
the [Order Value] column.

HTH
Dale

Hello Dale
thanks so much for your response. I'm a bit confused with the first part of
your answer. You write "in the first column, give the computer column a new
column name", where do you do that? Forgive my ignorance, but I'm trying to
understand.
is it in the expression builder? thanks
Your query might look something like:
[quoted text clipped - 21 lines]
Any help would be greatly appreciated. In advance, thank you.
Sylvie

--
HTH

Dale Fye

Message posted via AccessMonster.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top