# Cancel regular charges in billed periods

## Scenario

If you cancel a regular charge in a period that has already been billed, you might encounter a rounding difference between CCV and the total invoiced amount. It is because the CCV calculation is based on the charge effective start date and end date, whereas the invoice amount calculation has a dependency on the actual billing timing.

Note that this scenario happens only if you select From effective end date to end of the current billing period from When bill credit for recurring charges, based on billed period or credit period? when defining billing rules.

## Example

Suppose your customer creates a subscription to your storage service with a charge of \$25 per month from Feb 11, 2020 to Mar 10, 2020. The bill cycle day is the 11th day of the month.

Action Charge type CCV Invoiced amount Term start date Term end date Bill run target date
Create Subscription

Regular recurring charge \$25 \$25 2/11/2020

3/10/2020 2/11/2020

On Mar 1st, 2020, your customer cancels this subscription. The CCV data is then updated to \$25 * 19 (actual day in this service period) / 29 (days in this billing period) = \$16.379310344827586, and it may round up to \$17.

Since you have already billed the invoice, you have to credit back the invoice amount \$25 * 10/ 29 = \$8.620689655172414, and it may round up to \$9.

The following table describes the updated CCV and invoice data:

Action Charge type CCV Invoiced amount Term start date Term end date Bill run target date
Remove product Regular recurring charge \$17 \$25 - \$9 = \$16 2/11/2020 2/29/2020 3/1/2020

From the preceding table, the CCV is \$17 while the invoiced amount is \$16, which introduces a \$1 difference between the booking and billing amount.

## Solution

You can select Based on the total billing period amount and charged amount from When bill credit for recurring charges, based on billed period or credit period? when defining billing rules.
{"found_math": false, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 0, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 0, "mathjax_display_tex": 0, "mathjax_asciimath": 0, "img_math": 0, "codecogs_latex": 0, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0, "katex": 0, "math-container": 0, "wp-katex-eq": 0, "align": 0, "equation": 0, "x-ck12": 0, "texerror": 0, "url": "https://knowledgecenter.zuora.com/Zuora_Revenue/Zuora_Billing_-_Revenue_Integration/Handle_variances_for_reconciliation_between_booking_and_billing/Cancel_regular_charges_and_percentage_discounts_in_billed_periods", "fetch_time": 1718367344000000000, "content_mime_type": "text/html", "warc_filename": "crawl-data/CC-MAIN-2024-26/segments/1718198861546.27/warc/CC-MAIN-20240614110447-20240614140447-00559.warc.gz", "warc_record_offset": 307383048, "warc_record_length": 16608, "token_count": 497, "char_count": 1978, "score": 3.625, "int_score": 4, "crawl": "CC-MAIN-2024-26", "snapshot_type": "latest", "language": "en", "language_score": 0.8261297345161438, "file_path": "/sailhome/yjruan/project/latent-lm/data/processed/finemath-4plus/finemath-4plus/train-00017-of-00064.parquet"}