View Full Version : Index or filtering a date range


James Gatton
07-18-2001, 05:21 PM
I have a db with a field for when someone has enrolled into our program: EFFECTIVE.
I use a calculated field that's simply EFFECTIVE plus 365 days for the expiration date of their enrollment on the form.
I'm looking for one (or both) solutions.

First, I'm trying to set an index that will give me enrollments that expired 30 days previously up to 30 days past the current day. I can get 30 days prior and then up to infinity but don't know how to set the outer range. Does this have something to do with converting the date field to a character field?
Now, having this answer will allow me to move through the records one by one and generate a renewal record one at a time but obviously it would be easier to just print a range all at one shot. For the last couple of years I've been scrolling through the print filter window and selecting the range manually in order to print renewal letters. There must be a better way! I'm looking for solutions to either situation, please.

Thomas Henkel
07-20-2001, 06:56 AM
I am not quite sure WHY you would want to create an index to filter the records, so I won't address that.

Filtering the report is easy.

1. Set your report up to look exactly as you want it.

2. on the menu bar, select "Report".

3. In "report" select "detail properties"

4. In Detail Properties, select "Records"
In Records, set your Index to whatever you would like.
Then, set our filter to look something like this


This will select only those records that have an Effective date between 1month prior to today and one month from today.
When you save the report, the filter stays, so you won't need to select the range each time you run it.

Instead of using date() (current date), you may want to use an ask variable requesting a future date for record selection. that way, you wont be overlapping every time you run the report.


James Gatton
07-26-2001, 03:44 PM
Thanks, Tom!