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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Counting for Each day between two date fiels

Status
Not open for further replies.

JoseRosa

Technical User
Oct 12, 2002
4
CY
Hi there,
The tables are dbf (xbase).
I have a table with the following fiels:

1. Date of start
2. Date of end
3. Name
4. Persons

I want to have a report with the summarise of persons for each date within the range. Is there any way I can do this?

Thank you in advance..
Joseph


 
What about persons not in the date range, do you want them on the report at all? Software Training and Support for Macola, Crystal Reports and Goldmine
251-621-8972
dgilsdorf@mchsi.com
 
No I don't want to count the persons not on the range.

I want to insert a parameter with a range of two dates in order to count the persons between these days.

Thank you in advance
 
That did not answer my question.

Do you want these records on the report at all? You can keep these records on the report and only count the ones between the 2 dates.

So what do you want to do? Software Training and Support for Macola, Crystal Reports and Goldmine
251-621-8972
dgilsdorf@mchsi.com
 
Insert your date range parameter, and then in your record selection formula, put in something like this:

{DateField} in {?DateRangeParameter}

Then insert a summary count operation on the desired field.
Software Training and Support for Macola, Crystal Reports and Goldmine
251-621-8972
dgilsdorf@mchsi.com
 
Depending upon whether your database has a date or datetime field, you may discover that the record selection criteria does NOT pass the data to the database, or incorrectly does so unless you match data types (meaning date to date, or datetime to datetime).

Check the Database->Show SQL Query.

There should be a accurate Where clause being generated showing the dates being passed.

If not, either match the data types, or convert the parameter date range to datetimes in formulas and reference those formulas in the record selection criteria.

-k kai@informeddatadecisions.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top