Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Select Expert: Records from a previous month Post Reply Post New Topic
Author Message
bowja
Newbie
Newbie
Avatar

Joined: 07 Dec 2009
Location: Australia
Online Status: Offline
Posts: 31
Quote bowja Replybullet Topic: Select Expert: Records from a previous month
     Posted: 12 Dec 2010 at 12:46pm
Hello,
 
I am trying to create a filter using select expert which shows only the records with an {Order.FilledDate} in the month which was four months ago.  I want to be able to run this report each month without adjusting the parameters (my colleague runs it and doesn't like the formula side)
 
EG it is now December so I wish to show all records with a filled date in August.
 
I can run the report with ({Order.FilledDate} in CurrentDate -120 to CurrentDate -90) but this isn't quite what I need.
 
I want if current date xx/12/10 then show records with filled date xx/08/10 then in january it would be xx/01/11 and show records filled xx/09/10
 
Any assistance would be greatly appreciated.
 
Regards,
 
bowja
If you think you can or think you can't you are right - Paraphrased quote Henry Ford
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 13 Dec 2010 at 3:49am
({Order.FilledDate} in dateserial(year(currentdate),month(currentdate)-4,1) to dateserial(year(currentdate),month(currentdate)-3,1-1)
IP IP Logged
bowja
Newbie
Newbie
Avatar

Joined: 07 Dec 2009
Location: Australia
Online Status: Offline
Posts: 31
Quote bowja Replybullet Posted: 18 Dec 2010 at 10:15pm
Thank you DBlank this formula worked perfectly Smile
If you think you can or think you can't you are right - Paraphrased quote Henry Ford
IP IP Logged
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum