Call bill collection method, apparatus and device, and storage medium
By analyzing the operator and type of the call sheet file, and using the corresponding parsing template dialogue sheet field information for analysis, forming a data table and importing it into the database, the problem of difficulty in synchronizing the analysis of multiple types of call sheets in the existing technology is solved, and a more flexible and efficient call sheet collection system is realized.
Patent Information
- Application Number
- CN202411747511.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-29
- Publication Date
- 2025-04-15
AI Technical Summary
The existing technology is difficult to meet the market's demand for synchronous analysis of different types of calls. The existing system is mainly designed for a single type of calls, and it is difficult to deal with multiple types of calls.
By obtaining the call list file and analyzing its operator and type, obtaining the corresponding parsing template dialogue list field information for analysis, forming a data table and importing it into the call list collection database.
It realizes synchronous analysis of different types of call orders, meets the market's diverse call order needs, and improves the flexibility and efficiency of call order collection system.
Smart Images

Figure CN119835097A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of communication technology, and in particular to a call record collection method, device, equipment and storage medium. Background Art
[0002] The call bill collection process requires downloading the call bill, parsing the downloaded call bill, forming a text call bill in a standard format, and then uniformly analyzing the call bill through batch processing technology, eliminating invalid call bills, and finally unifying the batch price (calculating the call charges), generating detailed call bills, and centrally importing them into the system center database.
[0003] The current call bill collection systems are designed for a single call bill type and can only collect and analyze specific types of call bills, which is difficult to meet the market demand for synchronous analysis of different types of call bills. Therefore, how to solve the above technical problems is an urgent problem for technical personnel. Summary of the invention
[0004] In view of this, the present disclosure proposes a call record collection method, device, equipment and storage medium, which can meet the market demand for synchronous analysis of different types of call records.
[0005] According to a first aspect of the present disclosure, a method for collecting call records is provided, comprising:
[0006] Acquire a call record file, and parse the call record file to obtain an operator and a call record type corresponding to the call record file, wherein the call record file includes at least one call record field information;
[0007] Obtaining a parsing template corresponding to the operator and the call record type, and parsing field information of each call record in the call record file according to the parsing template to obtain a data table corresponding to the call record file;
[0008] The data table corresponding to the call record file is imported into the call record collection database.
[0009] In a possible implementation, before parsing the call record file to obtain the operator and the call record type corresponding to the call record file, the method further includes:
[0010] Parsing the file name of the call record file;
[0011] The file name of the call record file is stored in a pre-constructed file record table, and the processing status of the call record file is marked as unprocessed in the file record table.
[0012] In a possible implementation, after the data table corresponding to the call record file is imported into the call record collection database, the method further includes:
[0013] The processing status of the call record file in the file record table is changed to processed.
[0014] In a possible implementation, after the data table corresponding to the call record file is imported into the call record collection database, the method further includes:
[0015] The processing status of the call record file in the file record table is queried, and when the processing status of the call record file is processed, the call record file is deleted.
[0016] In a possible implementation, after obtaining the call record file, the method further includes: backing up the call record file to a designated directory.
[0017] According to a second aspect of the present disclosure, a device for collecting call records is provided, comprising:
[0018] A call record acquisition module, used to acquire a call record file, and parse the call record file to obtain the operator and call record type corresponding to the call record file, wherein the call record file includes at least one call record field information;
[0019] A call record parsing module, used to obtain a parsing template corresponding to the operator and the call record type, and parse the field information of each call record in the call record file according to the parsing template to obtain a data table corresponding to the call record file;
[0020] The data collection module is used to import the data table corresponding to the call record file into the call record collection database.
[0021] In a possible implementation, the device further includes a call bill information recording module;
[0022] The call record information recording module is used to parse the file name of the call record file before parsing the call record file to obtain the operator and call record type corresponding to the call record file; store the file name of the call record file in a pre-constructed file record table, and mark the processing status of the call record file as unprocessed in the file record table.
[0023] In a possible implementation, the call record information recording module is used to modify the processing status of the call record file in the file recording table to processed after the data collection module imports the data table corresponding to the call record file into the call record collection database.
[0024] According to a third aspect of the present disclosure, a call record collection device is provided, comprising: a processor; and a memory for storing processor executable instructions; wherein the processor is configured to execute the method described in the first aspect of the present disclosure.
[0025] According to a fourth aspect of the present disclosure, a non-volatile computer-readable storage medium is provided, on which computer program instructions are stored, wherein the computer program instructions, when executed by a processor, implement the method described in the first aspect of the present disclosure.
[0026] The present disclosure provides a method, device, equipment and storage medium for collecting call bills, the method comprising: obtaining a call bill file, parsing the call bill file, obtaining the operator and call bill type corresponding to the call bill file, wherein the call bill file includes at least one call bill field information; obtaining a parsing template corresponding to the operator and the call bill type, and parsing the field information of each call bill in the call bill file according to the parsing template to obtain a data table corresponding to the call bill file; importing the data table corresponding to the call bill file into a call bill collection database. By respectively setting interpretation modules for various call bill types under different operators to parse the call bills, the method disclosed in the present disclosure can meet the market demand for synchronous parsing of different types of call bills.
[0027] Further features and aspects of the present disclosure will become apparent from the following detailed description of exemplary embodiments with reference to the attached drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] The accompanying drawings, which are incorporated in and constitute a part of the specification, illustrate exemplary embodiments, features, and aspects of the disclosure and, together with the description, serve to explain the principles of the disclosure.
[0029] Figure 1 A flow chart showing a method for collecting call records according to an embodiment of the present disclosure is shown;
[0030] Figure 2 An example flow chart of a method for collecting call records according to an embodiment of the present disclosure is shown;
[0031] Figure 3 A schematic block diagram of a device for collecting call records according to an embodiment of the present disclosure is shown;
[0032] Figure 4 A schematic block diagram of a call bill collection device according to an embodiment of the present disclosure is shown. DETAILED DESCRIPTION
[0033] Various exemplary embodiments, features and aspects of the present disclosure will be described in detail below with reference to the accompanying drawings. The same reference numerals in the accompanying drawings represent elements with the same or similar functions. Although various aspects of the embodiments are shown in the accompanying drawings, the drawings are not necessarily drawn to scale unless otherwise specified.
[0034] The word “exemplary” is used exclusively herein to mean “serving as an example, example, or illustration.” Any embodiment described herein as “exemplary” is not necessarily to be construed as preferred or advantageous over other embodiments.
[0035] In addition, in order to better illustrate the present disclosure, numerous specific details are given in the following specific embodiments. It should be understood by those skilled in the art that the present disclosure can also be implemented without certain specific details. In some examples, methods, means, components and circuits well known to those skilled in the art are not described in detail in order to highlight the subject matter of the present disclosure.
[0036] <Method Example>
[0037] Figure 1 FIG. 1 is a flow chart showing a method for collecting call records according to an embodiment of the present disclosure. Figure 1 As shown, the method includes steps S1100-S1300.
[0038] S1100, obtain a call record file, and parse the call record file to obtain the operator and call record type corresponding to the call record file. The call record file includes at least one call record field information, and the call record field information may include a call record type identifier, a call type, a calling number, a called number, etc., which are not specifically limited here.
[0039] In a possible implementation, the acquisition of the call record file is based on the sftp server. Specifically, first log in to the sftp server for storing the call record file, and after logging in to the sftp server, download all the call record files stored on the sftp server, so that all the call record files on the sftp server can be obtained.
[0040] In a possible implementation, when downloading all the call record files stored on the sftp server, it is implemented based on a virtual machine. In this implementable method, considering the file transfer restrictions of the virtual machine, it is necessary to first compress all the call record files on the sftp server, and split the compressed files into multiple sub-compressed files according to the file transfer restrictions of the virtual machine. Then, the multiple sub-compressed files are sequentially loaded into the system that executes the method of this embodiment through the virtual machine. Finally, after the system completes the reception of all compressed sub-files, it merges and decompresses each compressed sub-file, so that all the call record files stored on the sftp server can be obtained.
[0041] In a possible implementation, multiple threads are configured in the system, and call record files are pulled and collected and processed simultaneously through the multiple threads, thereby improving the collection efficiency of batch call record files.
[0042] It should be noted here that the processing process of call record collection is the same for each call record file obtained. The call record collection method in the present disclosure is described below using a call record file as an example.
[0043] The current call record file to be processed is parsed to obtain the operator and call record type corresponding to the call record file, wherein the call record type includes at least one of voice, SMS, data and value-added.
[0044] After obtaining the operator and the bill type corresponding to the bill file, step S1200 is executed to obtain the parsing template corresponding to the operator and the bill type, and parse the field information of each bill in the bill file according to the parsing template to obtain the data table corresponding to the bill file. The parsing template records the parsing rules set by the operator for each field in the corresponding bill type, so that the parsing of each field in the corresponding bill type can be completed according to the parsing rules of each field.
[0045] It should be noted here that each operator has set corresponding parsing templates for different call bill types. For example, the call bill files under operator A include four types: voice, SMS, data and value-added. Operator A will set voice file parsing template A1 for voice type call bill files, SMS file parsing template A2 for SMS type call bill files, SMS file parsing template A3 for SMS type call bill files, and value-added file parsing template A4 for value-added type call bill files. For another example, the call bill files under operator B also include four types: voice, SMS, data and value-added. Operator B will set voice file parsing template B1 for voice type call bill files, SMS file parsing template B2 for SMS type call bill files, SMS file parsing template B3 for SMS type call bill files, and value-added file parsing template B4 for value-added type call bill files.
[0046] Each operator and the parsing template set for each call bill type are pre-loaded in the system implementing the method of this embodiment. In this way, after parsing the call bill file to obtain the supplier and call bill type corresponding to the supplier, the parsing template corresponding to the supplier and call bill type can be obtained from the system. For example, after parsing the call bill file, the operator obtained is A, and the call bill type is voice, then the parsing template A1 set by operator A for voice-type call bill files will be obtained from the system. For another example, after parsing the call bill file, the operator obtained is B, and the call bill type is SMS, then the parsing template B2 set by operator B for SMS-type call bill files will be obtained from the system.
[0047] In a possible implementation, in order to facilitate subsequent billing operations, the data tables corresponding to the bill files are created separately according to the month.
[0048] S1300, import the data table corresponding to the call bill file into the call bill collection database to complete the final call bill collection and storage operation. Specifically, the data table can be imported into the call bill collection database using a pre-insertion method, thereby improving the efficiency of importing the data table.
[0049] In a possible implementation, before parsing the call bill file to obtain the operator and call bill type corresponding to the call bill file, it also includes: parsing the file name of the call bill file, storing the file name of the call bill file in a pre-constructed file record table, and marking the processing status of the call bill file as unprocessed in the file record table. After importing the data table corresponding to the call bill file into the call bill collection database, it also includes: modifying the processing status of the call bill file in the file record table to processed. In this way, before the next step of processing the call bill file, the processing status corresponding to the current call bill file to be processed is first obtained from the file record table. If its processing status is unprocessed, steps S1200 and S1300 are executed to avoid repeated collection of call bill files in this way, thereby improving the effectiveness of call bill file collection. Furthermore, for performance considerations, a database index is created for the file name and processing status fields recorded in the file record table, so that the number of files stored in batches can be controlled at one time.
[0050] In a possible implementation, after the data table corresponding to the call record file is imported into the call record collection database, the process further includes: querying the processing status of the call record file in the file record table, and deleting the call record file when the processing status of the call record file is processed. In this way, the processed call record files can be cleaned up in time, thereby reducing their occupation of memory resources, so that more memory resources can be used for subsequent call record collection processing, thereby improving the processing efficiency of call record collection.
[0051] In a possible implementation, after obtaining the call record file, the method further includes: backing up the call record file to a designated directory, so that subsequent checking and searching of the call record file can be facilitated.
[0052] The present disclosure provides a method for collecting call records, including: obtaining a call record file, parsing the call record file, obtaining a call record type corresponding to the call record file, wherein the call record file includes at least one call record information; obtaining a parsing template corresponding to the call record type, and parsing the field information of each call record in the call record file according to the parsing template to obtain a data table corresponding to the call record file; and importing the data table corresponding to the call record file into a call record collection database. In the present disclosure, different parsing templates are configured for different call record types, so that different types of call records can be parsed synchronously.
[0053] <Method Example>
[0054] Figure 2 An example flow chart of a method for collecting call records according to an embodiment of the present disclosure is shown. Figure 2 As shown, the method includes steps S2010-S2019.
[0055] S2010, reading the name information of four types of call record files on the sftp server, wherein the four types of call record files are voice, SMS, data and value-added.
[0056] S2011, store the name information of all the call record files read into the pre-built file record table cu_js_cdr_file_log, and mark the processing status corresponding to the call record file as unprocessed.
[0057] S2012, back up all the read call record files to the specified directory.
[0058] S2013, multi-threaded parallel processing is used to obtain all call record files.
[0059] S2014, determine whether there is an unprocessed call record file in the file record table, if so, execute step S2015, if not, execute step S2019.
[0060] S2015, reading an unprocessed call record file, and collecting multiple call records in the call record file to obtain a data table corresponding to each call record.
[0061] S2016, importing the data tables corresponding to the various call records into the call record collection database in batches.
[0062] S2017, modifying the processing status of the currently processed call record file in the file record table to processed.
[0063] S2018, delete the call record file currently being processed on the server and return to step S2014.
[0064] S2019, sending notifications to other related subsystems so that the system can further perform operations such as call billing processing.
[0065] <Device Example>
[0066] Figure 3 FIG. 1 is a schematic block diagram of a device for collecting call records according to an embodiment of the present disclosure. Figure 3 As shown, the device 100 includes:
[0067] The call record acquisition module 110 is used to acquire a call record file and parse the call record file to obtain the operator and call record type corresponding to the call record file, wherein the call record file includes at least one call record field information;
[0068] The call record parsing module 120 is used to obtain a parsing template corresponding to the operator and the call record type, and parse the field information of each call record in the call record file according to the parsing template to obtain a data table corresponding to the call record file;
[0069] The data collection module 130 is used to import the data table corresponding to the call record file into the call record collection database.
[0070] In a possible implementation, the call bill collection device further includes a call bill information recording module;
[0071] The call record information recording module is used to parse the call record file to obtain the file name of the call record file before parsing the call record file to obtain the operator and call record type corresponding to the call record file; store the file name of the call record file in a pre-built file record table, and mark the processing status of the call record file as unprocessed in the file record table.
[0072] In a possible implementation, the call record information recording module is further used to modify the processing status of the call record file in the file recording table to processed after the data collection module imports the data table corresponding to the call record file into the call record collection database.
[0073] <Equipment Embodiment>
[0074] Figure 4 FIG. 1 is a schematic block diagram of a call record collection device according to an embodiment of the present disclosure. Figure 4 As shown, the call record collection device 200 includes: a processor 210 and a memory 220 for storing executable instructions of the processor 210. The processor 210 is configured to implement any of the above-mentioned call record collection methods when executing the executable instructions.
[0075] Here, it should be noted that the number of processors 210 may be one or more. Meanwhile, in the call record collection device 200 of the embodiment of the present disclosure, an input device 230 and an output device 240 may also be included. The processor 210, the memory 220, the input device 230 and the output device 240 may be connected via a bus or in other ways, which are not specifically limited here.
[0076] The memory 220 is a computer-readable storage medium that can be used to store software programs, computer executable programs, and various modules, such as the program or module corresponding to the call record collection method of the embodiment of the present disclosure. The processor 210 executes various functional applications and data processing of the call record collection device 200 by running the software programs or modules stored in the memory 220.
[0077] The input device 230 may be used to receive input numbers or signals. The signals may be key signals related to user settings and function control of the device / terminal / server. The output device 240 may include display devices such as display screens.
[0078] <Storage Medium Embodiment>
[0079] According to a fourth aspect of the present disclosure, a non-volatile computer-readable storage medium is also provided, on which computer program instructions are stored. When the computer program instructions are executed by the processor 210, any of the above-mentioned call record collection methods is implemented.
[0080] The embodiments of the present disclosure have been described above, and the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The selection of terms used herein is intended to best explain the principles of the embodiments, practical applications, or technical improvements to the technology in the market, or to enable other persons of ordinary skill in the art to understand the embodiments disclosed herein.
Claims
1. A method for collecting call records, characterized in that: include: Acquire a call record file, and parse the call record file to obtain an operator and a call record type corresponding to the call record file, wherein the call record file includes at least one call record field information; Obtaining a parsing template corresponding to the operator and the call record type, and parsing field information of each call record in the call record file according to the parsing template to obtain a data table corresponding to the call record file; The data table corresponding to the call record file is imported into the call record collection database.
2. The method according to claim 1, characterized in that Before parsing the call record file to obtain the operator and call record type corresponding to the call record file, the method further includes: Parsing the file name of the call record file; The file name of the call record file is stored in a pre-constructed file record table, and the processing status of the call record file is marked as unprocessed in the file record table.
3. The method according to claim 2, characterized in that After the data table corresponding to the call record file is imported into the call record collection database, the method further includes: The processing status of the call record file in the file record table is changed to processed.
4. The method according to claim 3, characterized in that After the data table corresponding to the call record file is imported into the call record collection database, the method further includes: The processing status of the call record file in the file record table is queried, and when the processing status of the call record file is processed, the call record file is deleted.
5. The method according to claim 1, characterized in that After obtaining the call record file, the method further includes: backing up the call record file to a designated directory.
6. A call record collection device, characterized in that: include: A call record acquisition module, used to acquire a call record file, and parse the call record file to obtain the operator and call record type corresponding to the call record file, wherein the call record file includes at least one call record field information; A call record parsing module, used to obtain a parsing template corresponding to the operator and the call record type, and parse the field information of each call record in the call record file according to the parsing template to obtain a data table corresponding to the call record file; The data collection module is used to import the data table corresponding to the call record file into the call record collection database.
7. The device according to claim 6, characterized in that It also includes a call list information recording module; The call record information recording module is used to parse the file name of the call record file before parsing the call record file to obtain the operator and call record type corresponding to the call record file; store the file name of the call record file in a pre-constructed file record table, and mark the processing status of the call record file as unprocessed in the file record table.
8. The device according to claim 7, characterized in that The call record information recording module is used to modify the processing status of the call record file in the file recording table to processed after the data collection module imports the data table corresponding to the call record file into the call record collection database.
9. A call record collection device, characterized in that: include: processor; a memory for storing processor-executable instructions; Wherein, the processor is configured to implement the method described in any one of claims 1 to 5 when executing the executable instructions.
10. A non-volatile computer-readable storage medium having computer program instructions stored thereon, characterized in that: When the computer program instructions are executed by a processor, the method according to any one of claims 1 to 5 is implemented.