josefmikhail2011
asked on
Can I include/not include sums in Access Reports based on dates?
I have a report designed so it shows issued policies within 0-15 days of the renewal date, same for 16-30 and 31-60 days and also for anything greater than 60 days.
All total numbers are correct, however, if I was to say that I only want to see figures in relation to the dates I put in how would I go about it? Currently if I put from the 1st Feb to the 28th Feb it will still show the total figure for anything greater than 60 days and total up the policy count which therefore gives a slightly inaccurate figure.
The query is as shown below, (bear in mind there are two further queries created before this):
SELECT qry_contract_certainty_ave rage.Count Ofcontract _certainty _time, qry_contract_certainty_ave rage.AvgOf contract_c ertainty_t ime, qry_contract_certainty_ave rage.SumOf Negative, qry_contract_certainty_ave rage.[SumO f0-15 days], qry_contract_certainty_ave rage.[SumO f16-30 days], qry_contract_certainty_ave rage.[SumO f31-60 days], qry_contract_certainty_ave rage.[SumO f>60 days], qry_contract_certainty_ave rage.Count OfInsurer_ Docs_issue d1, [CountOfInsurer_Docs_issue d1]-[Count Ofcontract _certainty _time] AS Expr2, ([SumOf16-30 days]+[SumOf0-15 days]+[SumOfNegative])/([C ountOfInsu rer_Docs_i ssued1]) AS Expr3
FROM qry_contract_certainty_ave rage;
So the dates are text fields that are placed in the form where the user enters in the dates and the report will take those dates and use the renewal date field to show records only between those dates.
Any advice or direction would be much appreciated, thanks.
All total numbers are correct, however, if I was to say that I only want to see figures in relation to the dates I put in how would I go about it? Currently if I put from the 1st Feb to the 28th Feb it will still show the total figure for anything greater than 60 days and total up the policy count which therefore gives a slightly inaccurate figure.
The query is as shown below, (bear in mind there are two further queries created before this):
SELECT qry_contract_certainty_ave
FROM qry_contract_certainty_ave
So the dates are text fields that are placed in the form where the user enters in the dates and the report will take those dates and use the renewal date field to show records only between those dates.
Any advice or direction would be much appreciated, thanks.
ASKER
The Where clause already exists in the first query I created, second query then uses the first and the third query as shown in my original post uses the second.
I just need to get the query to say if difference in the dates entered is greater than 60 do include the number in the total policy count. If difference is 60 or less then do not include in policy count.
Could I do anything with the report itself?
I just need to get the query to say if difference in the dates entered is greater than 60 do include the number in the total policy count. If difference is 60 or less then do not include in policy count.
Could I do anything with the report itself?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
That would not make the field visible and still count the figure included in the total, I want to avoid this by getting the report not to include the sum of anything greater than 60 days.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
WHERE RenewalDate Between Forms![FormName]![StartDat