I have a data from 2009 to 2013 and i have given the Year and Month as selecton parameters.
Now , by default i want to show the sales from 2009 to 2013(i.e till Max Years Max Month). but when user select a particular month then sales should some from 1/1/2009 till that selected month of 2013.
For Example
If user select Feb. then Sales should come from 1/1/2009 till 28/2/2013.
If user select 2012 in Year and Dec in Month Then Sales should come from 1/1/2009 till 31/12/2012.
Here you saying that give the sum of sales, where CalDate is greater then Minimum Date (which is 1/1/2009) in your case and the Max Date will be the one you select.
Hope the logic is clear to you.
Regards,
Kaushik Solanki
Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!