Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Searching Multiple Fields in a Query 1

Status
Not open for further replies.

BLutgen

Technical User
May 25, 2001
47
US
I am setting up an end of the month report for my company. I am running a query to give me the information for the report. All of the data is coming off of one table. My field names for the query is just general information such as quanity, price, est. ship date, etc. I have the customer as one field name, and it is sorting by ascending. At the end of the query my last two fields are the month and year functions, which are hidden. They are coded as follows.
Month([Date on EOR Rprt])
Year([Date on EOR Rprt])
In the criteria section I have [Enter Month] and [Enter Year] This works just like it is supposed to and pulls up all of the orders by the date on the EOR report which is the date they are entered. Now here comes my problem. I have two sets of dates to work from. I have the date the item was entered on the EOR report, but I also have a canceled date. To get an accurate report at the end of the month, not only do I need new entries, but also the canceled ones. How do I get my query to pluck out both the [Date on the EOR Rprt] as well as the dates from the [Cancel Date] field at the same time? Do I have to run two seperate queries? If so, how do I link them into a report? Thanks for any help.
 
Set up two hidden fields for year and month for the cancelled date. Add the same criterior you have for your existing fields to the new fields but in one line down on the grid. This will make use of the "OR" condition in the query.

cheers
 
Thanks for your help. I am new at this and your suggestion worked great. Now I just have to get it into the report. Thanks bunches!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top