BillStat (BRPT020)

Name conventions

Billing Statistics

BRPT020_< CompanyNumber>_< DateTime>_0[<Info>_<BatchId>].DAT

NameDescription
CompanyNumberThe company number in PayEx ledger system
DateTimeDate created in format YYYYMMDDHHMMSS
Info”BillStat_Billed” or “BillStat_Unbilled”
BatchIdBilling processId

Two examples of report files:

BRPT020_99999_20210101180000_0[BillStat_Billed_123456].DAT
BRPT020_99999_20210101181000_0[BillStat_Unbilled_123456].DAT

Change log

VersionDateDescriptionCreated by
1.02021-02-01

Created document

Tomas Kristoffersson


General information and explanation of records

The report BRPT020 presents statistics concerning recurrent products, non recurrent products and Usage aggregated on product group level for each “CompanyID”.
If your company has Revenue Accounting services, “CompanyID” is the same as “ProductId” in the associate “ProductCatalog”.
The report can be created on both billed and unbilled statistics

Billing Statistics Billed

The statistics in this report are based on specific billrun/billmonth. The information in this report is divided in four different groups.

Summarized statistics transaction types:

  1. Product group statistic (D1-Record)
  2. Recurring product statistic (D2-Record)
  3. Non recurring product statistic (D3-Record)
  4. Usage (D4-Record)

The report can be created with the following arguments:

  • Billrun, by using the processId from the billrun.
  • Billmonth, presents all billruns within the same month.

Billing Statistics UnBilled

The summarized billing statistic report are based on unbilled fees and usage. The information in the summarized statistic report is divided in different groups.

Summarized statistics transaction types:

  1. Product group statistic (D1-Record)
  2. Recurring product statistic (D2-Record)
  3. Non recurring product statistic (D3-Record)
  4. Usage (D4-Record)

Format description

The report always starts with a header (H) and always ends with a trailer (T).

All fields in the report are separated with semicolons ”;” and all data records (D) precedes with an information record (I) and followed by a summary record (S)

Record description

H - Header record

Field nameField no.FormatTypeDescription
Record type1HReq.Record type.
CompanyNumber2N(4)ReqYou receive the company number from PayEx.
CompanyName3X(40)ReqYour company name.
Billing cycle4X(10) YYYY-MM-01 – Billing cycle
BatchID5N(10) Batch id
Created date6N(6)ReqYYMMDD – Same date as in the file name.
Created time7N(4)ReqHHMM – Time when the file was created.

Example on the records appearance.
H;99999;CompanyName;2021-01-01; 00123; 211206;1200

Information record

I - Information record

The purpose of the information record is to explain the fields in the following data record (D).

NameNrFormatTypeDescription
Record type1I1, I2, I3,I4 and I9Req.Information record
X Description of the field in the data record

Data record

There are five different types of data record, each of them belonging to its information record.

D1 - Product Group statistics

Presents the product group statistic. The level of sum up is Product Group, Revenue Month and VAT rate.

NameNrFormatTypeDescription
Record type1D1Req.Data record, type 1
ProductGroup2NReq.Product group id
RevenueMonth3YYYY-MMReq.Revenue month
Description4X Product group description
VATRate5N(2),N(2)Req.VAT rate
TotalAmount6N(7).N(2-3)Req.Amount with 2 or 3 decimals according to specific company configuration

D2 - Recurring product statistic

This record presents the recurring product statistic. The level of sum up is Product Group, Revenue Month, Company Id, Product Code and VAT Rate.

NameNrFormatTypeDescription
Record type1D2Req.Data record, type 2
ProductGroup2NReq.Product group id
RevenueMonth3YYYY-MMReq.Revenue month
CompanyId4NReq.1 – 99999. 0 if missing
ProductCode5XReq.Product code
Description6X Product description
VATRate7N(2),N(2)Req.VAT rate
TotalAmount8N(7).N(2-3)Req.Amount with 2 or 3 decimals according to specific company configuration

D3 - Non recurring product statistic

This record presents the non recurring product statistic. The level of sum up is Product Group, Revenue Month, Description , Company Id and VAT Rate. Quantity is not included in this record for the reason that one product can be divided in separate revenue months.

NameNrFormatTypeDescription
Record type1D3Req.Data record, type 3
ProductGroup2NReq.Product group id
RevenueMonth3YYYY-MMReq.Revenue month
CompanyId4NReq.1 – 99999. 0 if missing
Description5X Product description
VATRate6N(2),N(2)Req.VAT rate
TotalAmount7N(7).N(2-3)Req.Amount with 2 or 3 decimals according to specific company configuration

D4 - Usage

This record presents the usage statistic. The level of sum up is Product Group, Revenue Month, Company Id, Usage Type, Description, Volume Code and VAT Rate.

NameNrFormatTypeDescription
Record type1D4Req.Data record, type 4
ProductGroup2NReq.Product group id
RevenueMonth3YYYY-MMReq.Revenue month
CompanyId4NReq.1 – 99999. 0 if missing
UsageType5NReq.Usage type
Description6X Usage type description
VolumeCode7NReq.Usage type volume code
VATRate8N(2),N(2)Req.VAT rate
Quantity9NReq.Quantity
PeakVolume10NReq.Peak volume, max value 2^63
OPeakVolume11NReq.Off peak volume, max value 2^63
CPeakVolume12NReq.Normal volume, max value 2^63
ConnectionAmount13N(7).N(2-3)Req.Starting fee with 2 or 3 decimals according to specific company configuration
TotalAMount14N(7).N(2-3)Req.Total amount with 2 or 3 decimals according to specific company configuration
TotalCost15N(7).N(2-3)Req.Total cost with 2 or 3 decimals according to specific company configuration

T - Trailer record

The trailer shows the total number of entries in the report.

NameNrFormatTypeDescription
Posttype1TReq.Trailer record
Total entries2NReq.Total number of entries

Example of summarized report

H;99999;Company Name;2021-01-01;123456;210101;1052
I1;ProductGroup;Description;RevenueMonth;VATRate;TotalAmount
D1;500;Abonnemang - Mobil;2021-01;25.00;39.00
D1;500;Abonnemang - Mobil;2021-02;25.00;306.00
D1;531;Trafik - Samtal;2020-10;25.00;1.38
D1;534;Trafik - Förmedlade tjänster;2020-10;0.00;40.00
D1;540;Påfyllning surf;2021-01;25.00;25.00
D1;565;Fakturaavgift;2021-02;25.00;98.00
I2;ProductGroup;RevenueMonth;CompanyId;ProductCode;Description;VATRate;TotalAmount
D2;565;2021-02;19498;960;Fakturaavgift;25.00;98.00
I3;ProductGroup;RevenueMonth;CustomerId;Description;VATRate;TotalAmount
D3;500;2021-01;150908;Huvudabonnemang 10 GB;25.00;88.00
D3;500;2021-01;151463;Abonnemangsrabatt 1;25.00;-49.00
D3;500;2021-02;150908;Huvudabonnemang 10 GB;25.00;269.00
D3;500;2021-02;151089;Testabonnemang;25.00;69.00
D3;500;2021-02;151402;8 GB;25.00;69.00
D3;500;2021-02;151404;3 GB;25.00;49.00
D3;500;2021-02;151463;Abonnemangsrabatt 2;25.00;-150.00
D3;540;2021-01;151406;Surf 1 GB;25.00;25.00
I4;ProductGroup;RevenueMonth;CustomerId;UsageType;Description;VolumeCode;VATRate;Quantity;PeakVolume;OPeakVolume;CPeakVolume;ConnectionAmount;TotalAmount;TotalCost
D4;531;2020-10;19471;302;Mobilsamtal;S;25.00;1;0;57;0;0.79;1.38;1.38
D4;534;2020-10;19485;902;Betalsamtal, förmedlad tjänst, Mobil;S;0.00;1;0;58;0;0.00;40.00;40.00
T;23

 

Created by Anders Göthberg on 2021/05/18 09:25