In(Recordset)

S

Steve

Is there a way to do something like this:

In(Rst!MyField) ?

and could it be used as the criteria for a field in a query?

Say MyField in a recordset contained 1,2,3 and 4. The above would then equate to
In(1,2,3,4).

Thanks!

Steve
 
T

Trevor Best

Is there a way to do something like this:

In(Rst!MyField) ?

and could it be used as the criteria for a field in a query?

Say MyField in a recordset contained 1,2,3 and 4. The above would then equate to
In(1,2,3,4).

something like:

Select f1, f2... from table1 where f1 in (select f1 from table2)
 
M

Mike MacSween

It's exactly that. Just look up 'IN operator' in help:

SELECT *
FROM Orders
WHERE ShipRegion In ('Avon','Glos','Som')

or using a sub-query:

SELECT *
FROM Orders
WHERE ShipRegion IN
(SELECT County
FROM Counties
WHERE Population > 1000000)

What exactly is it you are trying to do? Instead of using names like MyField
give us the real names and data and tell us what you want to happen.

Mike MacSween
 
C

Chuck Grimsby

Yes. Indeed, that's *exactly* what you do. However, since you
posted, I can only assume that you tried and it didn't work. What
*exactly* are you trying to do. (Code and/or query samples please.)
 
M

Mike MacSween

Steve said:
Mike,

Thanks for responding!

This part of a convention management database manages reservations for exhibit
booths. There are three tables:
TblExhibitor -- ExhibitorID, etc
TblReservation -- ReservationID, ExhibitorID, ...., ConfirmingLetterSent(Yes/No)
TblBoothAssigned -- BoothAssignedID, ReservationID, BoothNum, etc

The question surrounds TblReservation and marking ConfirmingLetterSent(Yes/No).
There's a form based on a query that returns all reservations where no
confirming letter has been sent.

I don't understand. Surely on this form the ConfirmingLetterSent is not
checked for any Exhibitors? Why do you want to clear it?

Mike
 

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