Add a new field in a query

B

Bob Levin

This can't be that difficult. A ran a query of 45 people. I want a separate
list of those going on the bus. In the query design view I tried to create
another field and name it "bus". Access will not let me. The field that I
name as "bus" keeps getting defaulted back to "Expr 1". when I go to data
view that field is named "Expr 1". It also keeps telling me to "Enter
Parameter Values". Help !!! All I want is to add a field and call it
"Bus", so I can run a query of the people going on the bus. Thanks much.
 
R

Rick Brandt

Bob said:
This can't be that difficult. A ran a query of 45 people. I want a
separate list of those going on the bus. In the query design view I
tried to create another field and name it "bus". Access will not let
me. The field that I name as "bus" keeps getting defaulted back to
"Expr 1". when I go to data view that field is named "Expr 1". It
also keeps telling me to "Enter Parameter Values". Help !!! All
I want is to add a field and call it "Bus", so I can run a query of
the people going on the bus. Thanks much.

The field needs a name as well as a value. Enter...

Bus: "Bus"
 
D

Douglas J. Steele

Queries are snapshots of tables: the field needs to be added to the table,
and then you can add it to the query.

What exactly is Bus supposed to be: a Yes/No field to indicate who's going
to be on the bus?
 
D

David Cox

or perhaps Bus: sum(1) if you are doing a group query on the travellers, or
bus: [travellers] if you want to be prompted for the number of travellers
 
B

Bob Levin

Thank You Rick.The field is now named Bus.That's good. However now all of the
cells in that column now contain the text, Bus. I don't want that. thanks if
you have a follow up. Bob Levin
 
R

Rick Brandt

Bob said:
Thank You Rick.The field is now named Bus.That's good. However now
all of the cells in that column now contain the text, Bus. I don't
want that. thanks if you have a follow up. Bob Levin

Well, what would you like it to contain? A field in a query that is not based on
a field from one of the base tables is either a constant that you simply type
into the grid or it is an expression that will pull data from someplace else.
 
B

Bob Levin

Exactly Douglas. Thank You. A Yes/No field is what I need.Can I get one more
little tip on that and I promise not to bother anymore.( for a while)
thanks

Bob Levin
 
B

Bob Levin

Thank you Joseph. Im clear now that data does not exist outside of a table.
Im learning little by little. appreciate all of your help. Also thanks to
Douglas and Rick.
 

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