• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 712
  • Last Modified:

Need a Crystal formula that will pull data from previous week monday to sunday

Trying to formulate a Crystal Report that I intend to run on a Monday morning and pull the previous monday to the Sunday :

If tomorows date is : 10/17/2001, I want to pull data regardless if it flows from one month to another from previous week : Monday 10/10/2011 to Sunday 10/16/2011

No grouping is being done.
0
John-S Pretorius
Asked:
John-S Pretorius
  • 2
  • 2
1 Solution
 
mlmccCommented:
Try

{YourDateField} In PreviousWeek

If that doesn't work

{YourDateField} >= CurrentDate - 7 AND {YourDateField} < CurrentDate

If it is a DateTime field

Date({YourDateField}) >= CurrentDate - 7 AND  Date({YourDateField}) < CurrentDate

mlmcc
0
 
John-S PretoriusAuthor Commented:
mlmcc, thank you for your responce - I'm pretty sure yours will work even better but this is what I ended up getting to work :

{EntriesExits.Time} in [(Minimum(lastfullweek)+1)
to (Maximum(lastfullweek)+1)]

I'm using Easyview Crystal batching to send the report and have to innitiate it between 11:55 and midnight on Sunday to get it for the full previous week - luckily no transactions occur after 9pm.

Are you familiar with Easyview ? I'm having an issue when running a report with Subreports in it, if so I would like to post a question about this soon.

Thanks again.
0
 
John-S PretoriusAuthor Commented:
Thank You
0
 
mlmccCommented:
I haven't heard of EasyView

mlmcc
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now