selecting a given Day in a list of days under Frequency field(IN?)

G

Guest

This is also on the forms- and have not gotten an answer need to know if at
all possible as soon as possible- Thanks

Thanks for your help I am still not seeming to explain what I need clearly

Right now I want to grab Today's DAY and pull up all records in the
query(criteria) with frequecy of doing all the jobs due today say- Wed .

I have in the criteria for the Frequency field =Format(Now(),"ddd"). It
does pull up ALL Wed ONLY frequency but want it to pull up if it says Mon,
Wed, Fri or Mon, Wed or any Combination.


Can I somehow use the In with what is already in the criteria row for the
frequecy field?
Doesn't seem to be working.

In("=Format(Now(),"ddd")" ) Tried # around the format code for both get
syntax error

any ideas?
Thanks,
Barb
 
G

Gary Walter

babs said:
This is also on the forms- and have not gotten an answer need to know if
at
all possible as soon as possible- Thanks

Thanks for your help I am still not seeming to explain what I need clearly

Right now I want to grab Today's DAY and pull up all records in the
query(criteria) with frequecy of doing all the jobs due today say- Wed .

I have in the criteria for the Frequency field =Format(Now(),"ddd"). It
does pull up ALL Wed ONLY frequency but want it to pull up if it says Mon,
Wed, Fri or Mon, Wed or any Combination.


Can I somehow use the In with what is already in the criteria row for the
frequecy field?
Doesn't seem to be working.

In("=Format(Now(),"ddd")" ) Tried # around the format code for both get
syntax error
I believe you are looking for InStr()


WHERE
InStr([Frequency], Format(Date(),"ddd"),1)>0;
 
G

Gary Walter

just to be clear, if you are designing your
query via the "grid"

Field: InStr([Frequency], Format(Date(),"ddd"),1)
Table:
Sort:
Show: <unchecked>
Criteria: > 0
Or:

will cause your Where clause to be:

WHERE
InStr([Frequency], Format(Date(),"ddd"),1) > 0;

If InStr() can find the 3-letter abbrev for today's Day
in the field [Frequency], it will return the position that
the abbrev starts at in the [Frequency] string.

So if it returns a position number greater than 0,
then the abbrev exists in the string.

Gary Walter said:
babs said:
This is also on the forms- and have not gotten an answer need to know if
at
all possible as soon as possible- Thanks

Thanks for your help I am still not seeming to explain what I need
clearly

Right now I want to grab Today's DAY and pull up all records in the
query(criteria) with frequecy of doing all the jobs due today say- Wed .

I have in the criteria for the Frequency field =Format(Now(),"ddd"). It
does pull up ALL Wed ONLY frequency but want it to pull up if it says
Mon,
Wed, Fri or Mon, Wed or any Combination.


Can I somehow use the In with what is already in the criteria row for the
frequecy field?
Doesn't seem to be working.

In("=Format(Now(),"ddd")" ) Tried # around the format code for both get
syntax error
I believe you are looking for InStr()


WHERE
InStr([Frequency], Format(Date(),"ddd"),1)>0;
 

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