WO2011026364A1 - 一种话单转换方法及话单转换系统 - Google Patents

一种话单转换方法及话单转换系统 Download PDF

Info

Publication number
WO2011026364A1
WO2011026364A1 PCT/CN2010/074014 CN2010074014W WO2011026364A1 WO 2011026364 A1 WO2011026364 A1 WO 2011026364A1 CN 2010074014 W CN2010074014 W CN 2010074014W WO 2011026364 A1 WO2011026364 A1 WO 2011026364A1
Authority
WO
WIPO (PCT)
Prior art keywords
conversion
bill
script
cdr
format
Prior art date
Application number
PCT/CN2010/074014
Other languages
English (en)
French (fr)
Inventor
魏霄鹏
Original Assignee
中兴通讯股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2011026364A1 publication Critical patent/WO2011026364A1/zh

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/02Details
    • H04L12/14Charging, metering or billing arrangements for data wireline or wireless communications

Definitions

  • the present invention relates to the field of business software, and in particular to a bill conversion method and a bill conversion system.
  • a bill conversion method includes: extracting a bill format conversion portion in a bill conversion platform, and configuring a conversion script to perform the conversion script in the conversion script Execution processing of the CDR conversion part; and the CDR conversion platform acquires the original CDR, and invokes the conversion script according to the format conversion requirement to perform the format conversion of the original CDR to generate the destination CDR.
  • the conversion script is an awk script.
  • the CDR conversion platform acquires the original CDR, and invokes the conversion script according to the format conversion requirement to perform format conversion of the original CDR.
  • the step of generating the destination CDR includes: acquiring the original vocabulary Single, read all the row records in the original bill in turn; call the awk conversion script according to the format conversion requirement; and run the awk conversion script with the row record as the input parameter, and then convert all the row records of the original bill into
  • the line record of the destination CDR format generates the destination CDR by the line record of the destination CDR format.
  • the method further includes: the awk conversion script returns a success or failure identifier to identify that the bill conversion succeeds or fails, and the conversion failure record is recorded.
  • the original bill includes a text file with a suffix named r, dat, txt.
  • the conversion script performs template configuration according to a preset format conversion requirement.
  • the conversion script is configured on-site according to a format conversion requirement.
  • the original bill acquisition is performed by using a timing acquisition and a classification storage manner.
  • the invention also discloses a bill conversion system, comprising a bill conversion platform and a conversion script configuration module, wherein the conversion script configuration module is configured to: configure a conversion script to execute a bill format conversion extracted from the bill conversion platform
  • the CDR conversion platform is configured to: obtain an original CDR, and invoke a conversion script configured by the conversion script configuration module according to the format conversion requirement to perform format conversion of the original CDR to generate a destination CDR.
  • the present invention separately configures the conversion script to perform the CDR format conversion by extracting the CDR format conversion part in the CDR conversion platform, so that the CDR format conversion can be realized simply and efficiently.
  • 1 is a schematic flow chart of obtaining an original bill according to an embodiment of the present invention
  • FIG. 2 is a schematic diagram of a bill conversion process using an awk script according to an embodiment of the present invention
  • FIG. 3 is a schematic diagram of field format conversion according to an embodiment of the present invention
  • 4 is a block diagram of a bill conversion system according to an embodiment of the present invention.
  • the bill conversion method of the specific embodiment of the present invention mainly includes the following steps: 1. Extracting a bill format conversion part in the bill conversion platform, and configuring a conversion script to perform the bill format conversion part in the conversion script. Perform processing
  • the bill conversion platform acquires the original bill, and invokes the conversion script according to the format conversion requirement to perform format conversion of the original bill to generate a destination bill.
  • the CDR format conversion part in the CDR conversion platform is first extracted, and the CDR conversion platform is used as a function platform for performing CDR conversion, and the CDR conversion can be realized by the execution of the CDR conversion software.
  • the most active part is its CDR format conversion part. Because of the various format conversion requirements in the project, it is often necessary to configure the corresponding CDR conversion program according to the actual format conversion requirements.
  • the CDR format conversion part is extracted from the CDR conversion platform, the conversion script is configured, and the CDR format conversion processing is performed in the conversion script.
  • the conversion script configuration can comprehensively analyze the format conversion requirements of the actual project, and pre-configure one or more template class conversion scripts to perform common format conversion requirements, thereby speeding up the execution of the bill conversion process by using the conversion script template.
  • Speed can also be based on the temporary engineering site format conversion requirements, the on-site configuration of the conversion script to adapt to the format conversion needs of the project site, in the case of similar template scenarios, can also be configured on the basis of the template, Speed up script configuration.
  • the template configuration and field configuration of the conversion script make the script configuration both versatile and flexible. Then, the CDR platform performs the CDR conversion by calling the configured conversion script.
  • the single-conversion platform's CDR conversion program such as file reading, writing, etc., does not need to be rewritten.
  • the CDR format conversion part converts the line records of the original CDR according to certain calculation rules, and synthesizes new text lines.
  • the script configuration uses the awk script, and the awk script is widely used in the linux system. Wide range of use, flexible use, rich built-in functions, suitable for processing various combinations of operations and output of fields in a row.
  • the embodiment of the present invention mainly focuses on a scene in which the original bill is a text file, and the text file includes files with the suffixes named "r", “dat”, "txt”, and the like.
  • the following example describes an awk conversion script.
  • Sourcedir 1 C: ⁇ zxinl0 ⁇ cdr316ftp 10
  • Sourcedirfiletype 1 * .r ; the type of the source file, r is the type of file suffix to be processed.
  • selectFilterCDR 1 c: ⁇ zxin 10 ⁇ selectcdr
  • /) && length($0) > 3)
  • FIG. 1 exemplarily describes an acquisition process of an original bill, including: Step SI 1 , timing a type of words from an FTP (File Transfer Protocol) server 1 and an FTP server 2 Single file, this type of CDR file can be configured by the file name wildcard in the configuration file (for example, the *.r file indicates all files with the suffix "r"), and the file obtained according to the file name wildcard is placed in the CDR.
  • FTP File Transfer Protocol
  • step S12 another type of CDR file is taken from the FTP server 1 and the FTP server 2, and the CDR file of the type can be configured by using the file name wildcard in the configuration file, and will be configured according to The file obtained by the filename wildcard is placed in the local directory 2 of the bill conversion platform.
  • the example of Figure 1 shows a network topology of bill conversion, in which the bill conversion function is executed by the local bill conversion platform, and the original bill file is stored in the remote FTP server. Through FTP, the local bill conversion platform can retrieve the original bill file from the FTP server and store it in local storage.
  • the original CDR file can be stored on the FTP server, and of course can also be stored on the server of other protocols.
  • FIG. 1 only describes two FTP servers exemplarily, but the original CDR file is not limited to only stored in two. On a server, it can also be stored on one server, or on more than two servers.
  • An FTP server can store different types of original CDR files. In actual operation, you can use the timing acquisition method.
  • the FTP server for multiple FTP servers.
  • the original CDR After the original CDR is obtained from the FTP server, it can be stored in the local storage by using the classified storage mode.
  • the classified storage mode is for each original CDR type, and the CDR conversion platform separately sets the local storage.
  • the directory after the original CDR file is removed from the FTP server, the file type of the original CDR can be determined according to the file name wildcard, and then stored in the corresponding directory, such as the local directory 1 or the local directory 2 mentioned above.
  • Regular acquisition and classification storage can automatically acquire the original CDR file and improve the speed of obtaining the original CDR file from the local. As shown in FIG.
  • the process of implementing the conversion of the CDR record format by using the awk script in the specific embodiment of the present invention includes: Step S21: reading an original CDR file in the local directory; the original CDR file is a text file. Step S22, opening the original bill file, reading a row of records in the file; Step S23, reading the awk conversion script corresponding to the format conversion requirement, and using the row record read in step S22 as a function entry parameter of the awk conversion script ( Enter the parameter, run the awk conversion script to convert the bill; in which, the awk conversion script can return the success or failure identifier to inform the line that the conversion is successful or the conversion fails.
  • Step S24 If the conversion is successful, the CDR record of the successful conversion is written into the destination CDR file; if the conversion fails, the CDR record of the conversion failure is written into the failed CDR file.
  • the specific bill conversion includes: In steps S31 and S32, for the row record of the original bill to be converted, the awk script is divided into points.
  • the separator definition according to the separator in the row record, separates the row record of the original bill into one or more field values SFieldl, SField2, SField3, etc.; (The separator defaults to a space, and can also be specified as "
  • the bill conversion platform loads and runs the awk script, converts the format, and the converted string content is controlled by the awk script, and the output string is the record format of the destination bill; the bill conversion platform loads the aw k script that can be converted in a single platform configuration file, then configured in a single aw k script files can also be converted in a single word for a platform configuration file is consistent with the syntax of awk awk statement.
  • the output content of step S33 can be:
  • the bill format conversion portion of the bill conversion platform 42 is extracted and executed by the conversion script configured by the conversion script configuration module 41, and the conversion script configuration module 41 is adapted.
  • the destination bill includes: a line record reading unit 421, which acquires the original bill 43 and sequentially reads all the line records in the original bill 43.
  • the conversion script running unit 422 loads the corresponding awk from the conversion script configuration module 41.
  • the present invention uses the bill conversion platform to load the awk conversion script, and then reads the local original bill file, runs the awk conversion script, and outputs the corresponding destination result format, and then the bill conversion platform writes the result record format.
  • the original CDR format to the destination CDR format is converted by extracting the CDR format conversion part from the CDR conversion platform and combining the awk script to convert the CDR format.
  • the CDR conversion platform program can be kept unchanged, only need to configure the conversion awk script file, the conversion script is simple to write, the field upgrade is convenient, and the work efficiency of on-site debugging and maintenance is improved, and the site is also improved. Flexible configuration and stable reliability of the bill conversion platform.
  • the present invention provides a bill conversion method and a bill conversion system, which can perform a bill format conversion by separately configuring a conversion script to perform a bill format conversion by using a bill format conversion portion extraction process in a bill conversion platform, thereby facilitating a simple and efficient manner.
  • Implement CDR format conversion

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)
  • Stored Programmes (AREA)

Description

一种话单转换方法及话单转换系统
技术领域 本发明涉及业务软件领域, 具体的说, 涉及一种话单转换方法及话单转 换系统。
背景技术 以往的话单转换中, 需要针对一套话单转换需求, 完整地编写一套相应 的话单转换程序代码, 这样的做法很不通用, 而且在实际应用中, 也存在着 很大的问题, 主要表现在: 一、 开发效率低, 处理原始话单文件及写目的话单文件的部分, 代码及 功能都重复; 二、 版本太多, 造成维护不方便, 如果发现了某个转换方面的问题, 需 要修改大量的版本及代码; 三、 程序复杂, 如果刚开始学习这种话单转换方法的话, 容易遗漏某个 文件处理的细节部分, 并且开发人员水平的差异也会造成问题的出现。
发明内容 有鉴于上述背景, 本发明提供了一种话单转换方法及话单转换系统, 能 够高效、 简便地实现话单转换。 为了解决上述技术问题, 本发明釆用了如下技术方案: 一种话单转换方法, 包括: 抽取话单转换平台中的话单格式转换部分, 配置转换脚本, 以在所述转 换脚本中进行所述话单格式转换部分的执行处理; 以及 话单转换平台获取原始话单, 根据格式转换需求调用所述转换脚本以执 行原始话单的格式转换, 生成目的话单。 在上述方法的一种实施例中, 所述转换脚本为 awk脚本。 在上述方法的一种实施例中, 所述话单转换平台获取原始话单, 根据格 式转换需求调用所述转换脚本以执行原始话单的格式转换, 生成目的话单的 步骤包括: 获取原始话单, 依次读取该原始话单中的所有行记录; 根据格式转换需求调用 awk转换脚本; 以及 以行记录作为入参, 运行所述 awk转换脚本, 依次将原始话单的所有行 记录转换为目的话单格式的行记录,由目的话单格式的行记录生成目的话单。 在上述方法的一种实施例中, 在运行所述 awk转换脚本之后, 所述方法 还包括: awk转换脚本通过返回成功或失败标识以标识话单转换成功或者失 败, 转换失败的话单记录被记录到失败话单中。 在上述方法的一种实施例中, 所述原始话单包括后缀名为 r、 dat、 txt的 文本文件。 在上述方法的一种实施例中, 所述转换脚本根据预设格式转换需求进行 模板配置。 在上述方法的一种实施例中,所述转换脚本根据格式转换需求现场配置。 在上述方法的一种实施例中, 原始话单获取釆用定时获取、 分类存放方 式进行。 本发明还公开了一种话单转换系统, 包括话单转换平台和转换脚本配置 模块, 所述转换脚本配置模块设置成: 配置转换脚本, 以执行从话单转换平 台中抽取出的话单格式转换部分; 所述话单转换平台设置成: 获取原始话单, 根据格式转换需求调用所述转换脚本配置模块配置的转换脚本以执行原始话 单的格式转换, 生成目的话单。 本发明通过将话单转换平台中的话单格式转换部分抽取处理, 而单独配 置转换脚本来执行话单格式转换,从而可以简便、 高效地实现话单格式转换。 附图概述 图 1为本发明实施例的获取原始话单的流程示意图; 图 2为本发明实施例的利用 awk脚本实现话单转换流程示意图; 图 3为本发明实施例的字段格式转换示意图; 图 4为本发明实施例的话单转换系统框图。
本发明的较佳实施方式
下面对照附图并结合具体实施方式对本发明做详细说明。 本发明具体实施方式的话单转换方法, 其主要包含如下步骤: 1、抽取话单转换平台中的话单格式转换部分, 配置转换脚本, 以在所述 转换脚本中进行所述话单格式转换部分的执行处理;
2、话单转换平台获取原始话单,根据格式转换需求调用所述转换脚本以 执行原始话单的格式转换, 生成目的话单。 在步骤 1中, 首先抽取话单转换平台中的话单格式转换部分, 话单转换 平台作为执行话单转换的功能平台, 可以通过话单转换软件的执行来实现话 单转换。 在执行话单转换时, 其最活跃的部分是其话单格式转换部分, 由于 工程中具有各种不同的格式转换需求, 因而常常需要根据实际格式转换需求 配置相应的话单转换程序。 在本发明的实施例中, 将话单格式转换部分从话 单转换平台中抽取出来, 配置转换脚本, 在转换脚本中执行话单格式转换的 处理。 转换脚本配置, 可以对实际工程的格式转换需求进行综合分析, 预先 配置出一个或多个模板类转换脚本, 以执行常见的格式转换需求, 从而通过 使用转换脚本模板而加快话单转换流程的执行速度; 也可以根据临时性的工 程现场的格式转换需求, 进行转换脚本的现场配置, 以适应工程现场的格式 转换需求, 在与模板场景类似的情况下, 还可在模板基础上进行配置, 以加 快脚本配置速度。 转换脚本的模板配置和现场配置使得脚本配置兼具通用性 和灵活性。 而后, 话单平台通过调用配置的转换脚本, 执行话单转换。 由于 抽取出话单转换平台中的话单格式转换部分, 并加以脚本配置, 从而使得话 单转换平台的话单转换程序中的诸如文件读取、 写入等基本不变的部分无需 重新编写, 话单转换程序编译完成后, 即使需要进行新的格式转换, 也无需 重新编译话单转换程序, 仅需修改转换脚本即可。 因而可以大大减少需要修 改的部分, 减少软件的编译次数和版本数, 提高开发效率, 增加话单转换平 台的可维护性。 话单格式转换部分是根据一定的运算规则对原始话单的行记录进行格式 转换, 组合成新的文本行, 在本例中, 脚本配置釆用 awk脚本, awk脚本广 泛应用在 linux系统中, 使用范围广, 使用方式灵活, 具有丰富的内置函数, 适合于处理行中的字段的各种组合运算及输出。 本发明的实施例, 主要针对原始话单是文本文件的场景, 文本文件包括 后缀名为 "r" 、 "dat" 、 "txt" 等的文件。 下面示例性的描述了一段 awk 转换脚本。
[cdrrecordtransl] ;源文件目录 1
sourcedir 1 = C:\zxinl0\cdr316ftp 10
sourcedirfiletype 1 =* .r ;源文件的类型, r是要处理的文件后缀类型。 selectFilterCDR 1 =c: \zxin 10\selectcdr
unSelectFilterCDRl=c:\zxinlO\unselectcdr ;异常话单或异常的话单记录: exceptionCDR 1 =c: \zxin 10\exceptioncdr
;该目录下的源文件用 shell的哪一部分处理 shellsectl=0 ;调用的 awk脚本文件固定为 awk317.sh, shellsectl=0表 示入参为 0,代表传入 awk317.sh脚本的入口参数为 0。
awk317.sh脚本如下: BEGIN{FS=T';ORS=,V\n"; OFS=T';]
if(ARGV[0] == T)
#sect=l时, 以下为怎样在生成的记录中使用序号的示例 if(($0 ~ /\|/) && length($0) >=3)
SERIAL— ΝΟ+=1
SERIAL— NO— STR=sprintf("%06d",SERIAL— NO) print 0,SERIAL_NO_STR,ARGV[0],substr($ 1 , 1 ,7),$1 ,$2
else
gsub("\r", "", $0) gsub("\n", "", $0) print 1000,$0
else if(ARGV[0] == "2")
#sect=2 时, 以下为怎样在生成的记录中使用序号,及原样引用其它 字段的示例 if(($0 〜 /\|/) && length($0) >=3) SERIAL— ΝΟ+=1
SERIAL— NO— STR=sprintf("%06d",SERIAL— NO) print 0,SERIAL_NO_STR,ARGV[0],substr($ 1,1,7)
else
gsub("\r", "", $0) gsub("\n", "", $0) print 1000,$0
如图 1所示, 图 1示例性的描述了原始话单的获取流程, 包括: 步骤 SI 1 , 定时从 FTP ( File Transfer Protocol, 文件传输协议)服务器 1 和 FTP服务器 2上取一种类型的话单文件,该种类型的话单文件可以通过配 置文件中的文件名通配符 (例如 *.r文件表示所有后缀名为 "r" 的文件)来 配置, 将根据文件名通配符取得的文件放到话单转换平台的本地目录 1中; 步骤 S12,定时从 FTP服务器 1和 FTP服务器 2上取另一种类型的话单 文件, 该种类型的话单文件可以通过配置文件中的文件名通配符来配置, 将 根据文件名通配符取得的文件放到话单转换平台的本地目录 2中。 图 1的示例展示的是一个话单转换的网络拓朴结构, 在该结构中, 话单 转换功能由本地的话单转换平台执行, 而原始话单文件存储在远程的 FTP月良 务器中, 通过 FTP, 本地的话单转换平台可从 FTP服务器获取原始话单文件 并存储在本地存储器中。 这是一种集中式的话单转换处理系统, 当然也可以 构成一种分布式的话单转换处理系统, 即话单转换功能平台与原始话单文件 所在地(例如 FTP服务器)集成在一起, 直接在原始话单所在地完成话单转 换。 原始话单文件可存储在 FTP服务器上, 当然也可以存储在其他协议的服 务器上, 并且, 图 1仅是示例性的描述了两个 FTP服务器, 但原始话单文件 并不限于仅存储在两个服务器上, 也可以是存储在一个服务器上, 或者两个 以上的服务器上。 一个 FTP服务器上可以存储不同类型的原始话单文件, 在 实际操作中, 可以釆用定时获取方式, 例如通过设置定时器, 在定时器的定 时时间到达, 则访问 FTP服务器(对于多个 FTP服务器, 可以釆用轮流访问 方式), 从 FTP服务器获取原始话单后, 釆用分类存放方式存放到本地存储 器中, 分类存放方式是针对每一种原始话单类型, 话单转换平台分别设置本 地存储目录, 在从 FTP服务器取下原始话单文件后, 可以根据文件名通配符 确定原始话单的文件类型, 然后存储到相应的目录中, 例如上述的本地目录 1或本地目录 2。 定时获取、分类存放可使原始话单文件获取自动进行, 并提 高从本地获取原始话单文件的速度。 如图 2所示, 本发明具体实施例的利用 awk脚本实现话单记录格式转换 的流程, 包括: 步骤 S21 , 读取本地目录中的一个原始话单文件; 原始话单文件为文本 文件。 步骤 S22, 打开该原始话单文件, 读取文件中的一行记录; 步骤 S23 , 读取格式转换需求相应的 awk转换脚本, 以步骤 S22读取的 行记录作为该 awk转换脚本的函数入口参数 (入参), 运行 awk转换脚本进 行话单转换; 其中, 可以通过 awk转换脚本返回成功或失败的标识来通知该 行记录转换成功或转换失败。 步骤 S24 , 如果转换成功, 把转换成功的话单记录写入目的话单文件中; 如果转换失败, 将转换失败的话单记录写入失败话单文件中。 如图 3所示, 具体的话单转换包括: 在步骤 S31和 S32, 对于待转换的原始话单的行记录, awk脚本按照分 隔符定义, 根据行记录中的分隔符, 把原始话单的行记录分隔为一个或多个 字段值 SFieldl、 SField2、 SField3等; (分隔符默认为空格, 也可以指定为" |" 等), 而后, awk脚本的语法利用 $1,$2,$3...这些字符来代表分隔好的每个 字段, awk脚本输出记录时, 就是对这些字段进行组合和运算。 S33 , 话单转换平台加载并运行 awk脚本, 对格式进行转换, 转换后输 出的字符串内容由 awk脚本进行控制, 输出的字符串即为目的话单的记录格 式; 话单转换平台加载的 awk脚本, 可以是在话单转换平台配置文件中配置 的一个单独的 awk脚本文件, 也可以是在话单转换平台配置文件中配置的一 段符合 awk语法的 awk语句。 步骤 S33的输出内容可以为:
1 ) S32中字段的随意完整的组合;
2 ) S32中字段的随意截取和合并;
3 )非 S32中字段的输出, 也即可以输出常量的字符串及符号等;
4 )其它符合 awk语法格式的运算符, 函数调用, 及语句输出。 其中, 完整组合就是用原始话单格式中的完整字段进行组合, 字段截取 和合并就是取部分字段或把取得的部分字段进行合并。 例如: 原来字段为 1234|abcd|5678 输出字段可以为 12345678|abcd, 即完整组合。 也可以为 1256ab|cd, 即截取和合并。 甚至可以加上特别的常量及符号: 如输出 ztel234|zteabcd|91011 | !@#5678。 在步骤 S34和 S35 ,将目的话单格式的字符串 DFieldl、 DField2、 DField3 等形成目的话单格式的行记录, 将目的话单格式的行记录写入到目的话单文 件中。
下面是一个话单转换示例, 假设原始话单格式为 1 |2|3|4|5 目的话单需要取第 1,3,5字段, 也就是需要格式为 1|3|5 则需要写的 awk脚本为: BEGIN{FS=T';ORS=,V\n"; OFS=T';}
if(ARGV[0] == "0")
print $1, $3, $5
需要说明的是, 在上文中以步骤的形式示出并描述了本发明方法实施例 的技术方案, 这些步骤可以在诸如一组计算机可执行指令的计算机系统中执 行。 虽然在相关的附图中示出了逻辑顺序, 但是在某些情况下, 可以以不同 于此处的顺序执行所示出或描述的步骤。 另外, 在不冲突的情况下, 本发明
如图 4所示, 本发明具体实施方式的话单转换系统中, 话单转换平台 42 的话单格式转换部分被抽取出而由转换脚本配置模块 41 配置的转换脚本执 行 ,转换脚本配置模块 41完成适应于不同格式转换需求的各种转换脚本的配 置; 话单转换平台 42获取原始话单 41 , 根据话单转换需求从转换脚本配置 模块 41中加载并运行对应的转换脚本,将原始话单转换为目的话单,其包括: 行记录读取单元 421 ,获取原始话单 43 ,依次读取该原始话单 43中的所 有行记录; 转换脚本运行单元 422,从转换脚本配置模块 41加载对应的 awk转换脚 本, 以行记录作为字符串入口参数, 运行 awk转换脚本, 依次将原始话单 43 的所有行记录转换为目的话单格式的记录, 由目的话单格式的记录构成目的 话单 44。 综上所述, 本发明利用话单转换平台加载 awk转换脚本, 而后读取本地 的原始话单文件, 运行 awk转换脚本, 输出相应的目的结果格式, 然后话单 转换平台把该结果记录格式写入目的话单中。 通过从话单转换平台中抽取出 话单格式转换部分, 结合 awk脚本进行话单格式转换的方式来完成原始话单 格式到目的话单格式的转换。 相比于原有技术, 话单转换平台程序可以保持 不变, 只需要配置转换 awk脚本文件, 转换脚本编写方式简单, 现场升级方 便, 并且提高了现场调试和维护的工作效率, 也提高了现场的灵活配置性及 话单转换平台的稳定可靠性。
本领域普通技术人员可以理解上述方法中的全部或部分步骤可通过程序 来指令相关硬件完成, 所述程序可以存储于计算机可读存储介质中, 如只读 存储器、 磁盘或光盘等。 可选地, 上述实施例的全部或部分步骤也可以使用 一个或多个集成电路来实现。 相应地, 上述实施例中的各模块 /单元可以釆用 硬件的形式实现, 也可以釆用软件功能模块的形式实现。 本发明不限制于任 何特定形式的硬件和软件的结合。 尽管本发明结合特定实施例进行了描述, 但是对于本领域的技术人员来 说, 可以在不背离本发明的精神或范围的情况下进行修改和变化。 这样的修 改和变化被视作在本发明的范围和附加的权利要求书范围之内。
工业实用性 本发明提供一种话单转换方法及话单转换系统, 通过将话单转换平台中 的话单格式转换部分抽取处理, 而单独配置转换脚本来执行话单格式转换, 从而简便、 高效地实现话单格式转换。

Claims

权 利 要 求 书
1、 一种话单转换方法, 包括:
抽取话单转换平台中的话单格式转换部分, 配置转换脚本, 以在所述转 换脚本中进行所述话单格式转换部分的执行处理; 以及 话单转换平台获取原始话单, 根据格式转换需求调用所述转换脚本以执 行原始话单的格式转换, 生成目的话单。
2、 如权利要求 1所述的方法, 其中: 所述转换脚本为 awk脚本。
3、 如权利要求 2所述的方法, 其中: 所述话单转换平台获取原始话单, 根据格式转换需求调用所述转换脚本 以执行原始话单的格式转换, 生成目的话单的步骤包括: 获取原始话单 , 依次读取该原始话单中的所有行记录; 根据格式转换需求调用 awk转换脚本; 以及 以行记录作为入参, 运行所述 awk转换脚本, 依次将原始话单的所有行 记录转换为目的话单格式的行记录,由目的话单格式的行记录生成目的话单。
4、 如权利要求 3所述的方法, 其中: 在运行所述 awk转换脚本之后, 所述方法还包括: awk转换脚本通过 返回成功或失败标识以标识话单转换成功或者失败, 转换失败的话单记录被 记录到失败话单中。
5、 如权利要求 1-4任一所述的方法, 其中: 所述原始话单包括后缀名为 r、 dat和 txt中的一种或多种的文本文件。
6、 如权利要求 5所述的方法, 其中: 所述配置转换脚本的步骤包括: 根据预设格式转换需求使用模板配置所 述转换脚本。
7、 如权利要求 5所述的方法, 其中: 所述配置转换脚本的步骤包括: 根据格式转换需求现场配置所述转换脚 本。
8、 如权利要求 1-4任一所述的方法, 其中:
在话单转换平台获取原始话单的步骤中,釆用定时获取原始话单和 /或分 类存放原始话单的方式。
9、 一种话单转换系统, 包括话单转换平台和转换脚本配置模块, 其中: 所述转换脚本配置模块设置成: 配置转换脚本, 以执行从话单转换平台 中抽取出的话单格式转换部分; 所述话单转换平台设置成: 获取原始话单, 根据格式转换需求调用所述 转换脚本配置模块配置的转换脚本以执行原始话单的格式转换, 生成目的话 单。
10、 如权利要求 9所述的话单转换系统, 其中: 所述转换脚本为 awk脚本。
PCT/CN2010/074014 2009-09-04 2010-06-17 一种话单转换方法及话单转换系统 WO2011026364A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN200910189892A CN101651940A (zh) 2009-09-04 2009-09-04 一种话单转换方法及话单转换系统
CN200910189892.3 2009-09-04

Publications (1)

Publication Number Publication Date
WO2011026364A1 true WO2011026364A1 (zh) 2011-03-10

Family

ID=41673999

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2010/074014 WO2011026364A1 (zh) 2009-09-04 2010-06-17 一种话单转换方法及话单转换系统

Country Status (2)

Country Link
CN (1) CN101651940A (zh)
WO (1) WO2011026364A1 (zh)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101651940A (zh) * 2009-09-04 2010-02-17 中兴通讯股份有限公司 一种话单转换方法及话单转换系统
CN103902559B (zh) * 2012-12-26 2017-05-10 中兴通讯股份有限公司 一种文件名转换方法及装置

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1741558A (zh) * 2004-08-23 2006-03-01 华为技术有限公司 一种通话费用的计费方法
CN101184133A (zh) * 2007-12-25 2008-05-21 天柏宽带网络科技(北京)有限公司 一种话单文件的转换方法
KR20080052855A (ko) * 2006-12-08 2008-06-12 에스케이 텔레콤주식회사 개인화된 멀티미디어 포맷 변환 서비스 방법과 이를 위한멀티미디어 포맷 변환 서버
CN101651940A (zh) * 2009-09-04 2010-02-17 中兴通讯股份有限公司 一种话单转换方法及话单转换系统

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1741558A (zh) * 2004-08-23 2006-03-01 华为技术有限公司 一种通话费用的计费方法
KR20080052855A (ko) * 2006-12-08 2008-06-12 에스케이 텔레콤주식회사 개인화된 멀티미디어 포맷 변환 서비스 방법과 이를 위한멀티미디어 포맷 변환 서버
CN101184133A (zh) * 2007-12-25 2008-05-21 天柏宽带网络科技(北京)有限公司 一种话单文件的转换方法
CN101651940A (zh) * 2009-09-04 2010-02-17 中兴通讯股份有限公司 一种话单转换方法及话单转换系统

Also Published As

Publication number Publication date
CN101651940A (zh) 2010-02-17

Similar Documents

Publication Publication Date Title
US8078915B2 (en) System and method for verifying operation of a target system
CN105786998B (zh) 数据库中间件系统及利用其处理数据的方法
CN112000741B (zh) 内外网数据交换系统、方法、装置、计算机设备和介质
CN111290753B (zh) 前端开发环境的搭建方法、装置、设备及存储介质
US20060265469A1 (en) XML based scripting framework, and methods of providing automated interactions with remote systems
US20080208830A1 (en) Automated transformation of structured and unstructured content
CN110555074B (zh) 定时抽取和加工数据的方法、终端及计算机可读存储介质
CN109460358B (zh) 基于Cmdb的配置管理方法及系统
WO2022127196A1 (zh) 应用识别方法、装置、设备及存储介质
CN115480753A (zh) 应用集成系统及相应计算机设备和存储介质
CN1716960B (zh) 产生包括xpath表达式的xml表示的管理事务的方法和设备
CN115329170A (zh) 网页抓取方法、装置、设备以及存储介质
CN116204239A (zh) 业务处理方法、装置和计算机可读存储介质
WO2011026364A1 (zh) 一种话单转换方法及话单转换系统
WO2015176443A1 (zh) 企业互联网应用的处理方法及装置
CN106570152B (zh) 一种手机号码的海量提取方法及系统
JP6097054B2 (ja) 制御システム及び制御方法
KR101982308B1 (ko) 프로토콜 모델 생성 장치 및 모델링 방법
US20190121681A1 (en) Framework for integrating a user device and a mainframe system
JP3603718B2 (ja) メイク情報解析によるプロジェクト内容解析方法及びそのシステム並びに情報記録媒体
JP5469834B2 (ja) 端末管理システム
US8775528B2 (en) Computer readable recording medium storing linking keyword automatically extracting program, linking keyword automatically extracting method and apparatus
CN104065507A (zh) 基于双平台复用技术的接入设备业务配置方法及系统
JP5253115B2 (ja) プログラム変換装置、プログラム分析装置、プログラム変換方法、プログラム分析方法、およびプログラム
CN108762745B (zh) 业务的脚本生成方法及装置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 10813286

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 10813286

Country of ref document: EP

Kind code of ref document: A1