[go: up one dir, main page]

CN110263316B - A file processing method, device and computer equipment - Google Patents

A file processing method, device and computer equipment Download PDF

Info

Publication number
CN110263316B
CN110263316B CN201910569703.9A CN201910569703A CN110263316B CN 110263316 B CN110263316 B CN 110263316B CN 201910569703 A CN201910569703 A CN 201910569703A CN 110263316 B CN110263316 B CN 110263316B
Authority
CN
China
Prior art keywords
file
data
field
typesetting
fund
Prior art date
Legal status (The legal status 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 status listed.)
Active
Application number
CN201910569703.9A
Other languages
Chinese (zh)
Other versions
CN110263316A (en
Inventor
胡创大
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
WeBank Co Ltd
Original Assignee
WeBank Co Ltd
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 WeBank Co Ltd filed Critical WeBank Co Ltd
Priority to CN201910569703.9A priority Critical patent/CN110263316B/en
Publication of CN110263316A publication Critical patent/CN110263316A/en
Priority to PCT/CN2020/091378 priority patent/WO2020259141A1/en
Application granted granted Critical
Publication of CN110263316B publication Critical patent/CN110263316B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/10Text processing
    • G06F40/166Editing, e.g. inserting or deleting
    • G06F40/177Editing, e.g. inserting or deleting of tables; using ruled lines
    • G06F40/18Editing, e.g. inserting or deleting of tables; using ruled lines of spreadsheets
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/10Text processing
    • G06F40/189Automatic justification

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Document Processing Apparatus (AREA)

Abstract

本发明公开了一种文件处理方法、装置及计算机设备,涉及涉及金融科技领域,用于为基金文件提供一种新的处理方式,提高处理基金文件的准确性。该方法包括:确定待转换的基金文件;读取基金文件中的交易记录数据,其中,交易记录数据包括按照预定顺序拼接组成的M条子交易数据,M条子交易数据中的每条子交易数据均包括N个字段的字段数据,N个字段中的每个字段的字段名各不相同;按照EXCEL文件的排版格式,将每条子交易数据的N个字段划分为N列以及根据对应每列的字段的字段名设置该列的列标识进行EXCEL排版,以获得针对交易记录数据的第一排版结果;根据第一排版结果,生成与基金文件对应的EXCEL文件。

The present invention discloses a file processing method, device and computer equipment, which relates to the field of financial technology and is used to provide a new processing method for fund files to improve the accuracy of processing fund files. The method includes: determining a fund file to be converted; reading transaction record data in the fund file, wherein the transaction record data includes M sub-transaction data spliced in a predetermined order, each of the M sub-transaction data includes field data of N fields, and the field name of each field in the N fields is different; according to the typesetting format of the EXCEL file, the N fields of each sub-transaction data are divided into N columns and the column identifier of the column is set according to the field name of the field corresponding to each column for EXCEL typesetting, so as to obtain a first typesetting result for the transaction record data; according to the first typesetting result, an EXCEL file corresponding to the fund file is generated.

Description

File processing method and device and computer equipment
Technical Field
The present invention relates to the technical field of financial science and technology (Fintech), and in particular, to a method and apparatus for processing a file, and a computer device.
Background
In the prior art, along with the continuous development of technology, more and more technologies are applied in the financial field, and the traditional financial industry is gradually changing to the financial technology. Specifically, when the current fund file is used for data recording, the open fund service data exchange protocol of the central data exchange platform needs to be satisfied, that is, each transaction data in the data file in the fund file is a fixed-length message, and the fixed-length message comprises a plurality of field parameters.
However, if the data file needs to be checked or modified, only the manual operation is used to locate and check the value corresponding to a certain field or modify the value of the field, so that the processing efficiency is low and the error is easy to occur.
Therefore, the problems of lower processing efficiency and poorer accuracy exist in the prior art when the fund file is processed.
Disclosure of Invention
The embodiment of the invention provides a file processing method, a device and computer equipment, which are used for providing a new processing mode for a fund file so as to improve the accuracy of processing the fund file and the efficiency of processing the file.
In a first aspect, a method for processing a file is provided, the method comprising:
Determining a fund file to be converted;
Reading transaction record data in the fund file, wherein the transaction record data comprises M pieces of sub transaction data formed by splicing according to a preset sequence, each piece of sub transaction data in the M pieces of sub transaction data comprises field data of N fields, the field names of each field in the N fields are different, and M and N are integers which are greater than or equal to 1;
Dividing N fields of each piece of sub transaction data into N columns according to the typesetting format of the EXCEL file, and setting column identification of each column according to the field name of the field corresponding to each column to perform EXCEL typesetting so as to obtain a first typesetting result aiming at the transaction record data;
and generating an EXCEL file corresponding to the foundation file according to the first typesetting result.
According to the technical scheme, the transaction record data formed by splicing the N fields of M rows in the foundation file is divided into N columns according to the N fields of each piece of sub transaction data, and the column identification of the column is set according to the field name of the field corresponding to each column to perform EXCEL typesetting, so that different fields in each piece of sub transaction record data are divided, a user can know the field content in each piece of sub transaction record data clearly, and the accuracy of processing the foundation file is improved.
In an alternative embodiment, the method further comprises:
translating field names of the N fields in a second language different from the first language to obtain N field identifiers expressed in the second language, wherein the field names of the N fields in the first typesetting result are expressed in the first language;
Setting N field identifiers expressed in the second language and N column identifiers in the first typesetting result as one column respectively according to a mode that the field identifiers used for expressing the same field name are correspondingly arranged with the column identifiers, so as to obtain a second typesetting result for the N fields;
And generating an EXCEL file corresponding to the fund file according to the first typesetting result, wherein the EXCEL file comprises:
and generating an EXCEL file corresponding to the foundation file according to the first typesetting result and the second typesetting result.
According to the technical scheme, the field names of the N fields are translated in the second language different from the first language, N field identifiers expressed in the second language are respectively and correspondingly set into one row with N row identifiers in the first typesetting result for typesetting, so that users who are used to reading in different languages can directly acquire the meaning expressed by the field names, the operation of the users is reduced, and the user experience is improved.
In an alternative embodiment, obtaining the second typesetting result for the N subsections includes:
Determining a bit number identifier corresponding to each field according to the bit number occupied by each field in the N fields;
typesetting the digit identification of each field and the field identification or column identification corresponding to the field to obtain a field digit typesetting result;
And updating the second typesetting result according to the field digit typesetting result.
According to the technical scheme, the digit identification corresponding to each field is determined, and then the digit identification of each field is typeset corresponding to the field identification or the column identification corresponding to the field, so that a field digit typesetting result is obtained, that is, a user can see the EXCEL file displayed with the digit identifications of N fields, and therefore when the user needs to check whether the digit of the field accords with the protocol specification, the digit identification of the N fields can be determined directly according to the displayed digit identifications of the N fields, and the processing efficiency of processing the foundation file is improved.
In an alternative embodiment, the method further comprises:
Determining fixed file description data in the fund files, wherein the fixed file description data comprises data with the same type included in all the fund files represented by a financial data protocol adopted by the fund files;
According to the typesetting format of the fixed file description data in the foundation file, performing EXCEL typesetting on the fixed file description data to obtain a third typesetting result aiming at the fixed file description data;
And generating an EXCEL file corresponding to the fund file according to the first typesetting result, wherein the EXCEL file comprises:
and generating an EXCEL file corresponding to the foundation file according to the first typesetting result and the third typesetting result.
According to the technical scheme, the fixed file description data in the fund files are typeset, and then the fixed file description data and the first typesetting result are combined to generate the EXCEL files corresponding to the fund files, so that the generated EXCEL files correspond to the fund files, and a user can accurately use all data contents of the fund files through the EXCEL files, so that the user experience is improved.
In an alternative embodiment, after generating the EXCEL file corresponding to the fund file, the method further comprises:
Receiving an editing operation for the EXCEL file;
determining a response result of the edited data in the EXCEL file to the editing operation according to the editing operation;
carrying out validity check on the response result according to the data attribute of the edited data, wherein the data attribute comprises the number of bits occupied by the data and/or the data retention level;
and if the test is not passed, the response to the editing operation is canceled.
In the above technical solution, an editing operation (e.g., a modification operation) for the EXCEL file may be received, and then, according to the editing operation, a response result of the edited data in the EXCEL file to the editing operation is determined, so that validity verification is performed on the response result according to a data attribute of the edited data, that is, when the user edits the EXCEL file, verification may be performed on the user edited data, so as to improve accuracy of processing the file. When the verification fails, the response to the editing operation, that is, the illegal editing of the user is prevented during the editing operation, may be canceled to determine the validity of the edited data.
In an alternative embodiment, the method further comprises:
Determining an EXCEL file to be converted, wherein the EXCEL file to be converted is the EXCEL file obtained by conversion according to the foundation file;
performing typesetting conversion on the EXCEL file to be converted according to the typesetting format of the foundation file to obtain a fourth typesetting result;
and generating a fund file corresponding to the EXCEL file to be converted according to the fourth typesetting result.
According to the technical scheme, the EXCEL file obtained through conversion according to the foundation file can be processed, namely, the EXCEL file to be converted is subjected to typesetting conversion according to the typesetting format of the foundation file, and then the foundation file corresponding to the EXCEL file to be converted is generated. That is, the converted EXCEL file can be converted into the fund file again, so that a user can process transaction record data of the fund file in the EXCEL file, and then the processed EXCEL file is converted into the fund file, so that user experience is improved.
In an alternative embodiment, the method further comprises:
in the process of converting the EXCEL file to be converted into a corresponding fund file, carrying out validity check on key data, wherein the key data comprises at least one of field length, parameter number and data line number;
And when the key data passes the validity check, continuing to convert the EXCEL file to be converted into the corresponding fund file.
In the technical scheme, the validity of the key data can be checked in the process of converting the EXCEL file to be converted into the corresponding fund file, so that the validity of the fund file converted from the EXCEL file can be further ensured, and the accuracy of file processing is improved.
In a second aspect, the present application provides a document processing apparatus, the apparatus comprising:
the first determining module is used for determining the fund file to be converted;
The reading module is used for reading transaction record data in the fund file, wherein the transaction record data comprises M pieces of sub transaction data formed by splicing according to a preset sequence, each piece of sub transaction data in the M pieces of sub transaction data comprises field data of N fields, the field names of each field in the N fields are different, and M and N are integers which are larger than or equal to 1;
The first typesetting module is used for dividing N fields of each piece of sub transaction data into N columns according to the typesetting format of the EXCEL file and setting column identifications of the columns according to field names of the fields corresponding to each column so as to obtain a first typesetting result for the transaction record data;
and the first processing module is used for generating an EXCEL file corresponding to the foundation file according to the first typesetting result.
In an alternative embodiment, the apparatus further comprises a second determining module configured to:
translating field names of the N fields in a second language different from the first language to obtain N field identifiers expressed in the second language, wherein the field names of the N fields in the first typesetting result are expressed in the first language;
The device also comprises a second typesetting module, a first typesetting module and a second typesetting module, wherein the second typesetting module is used for setting N field identifiers expressed in the second language and N column identifiers in the first typesetting result into a column respectively according to a mode that the field identifiers used for expressing the same field name are correspondingly arranged with the column identifiers so as to obtain a second typesetting result aiming at the N fields;
The device also comprises a second processing module, which is used for generating an EXCEL file corresponding to the fund file according to the first typesetting result and the second typesetting result.
In an alternative embodiment, the second determining module is further configured to:
Determining a bit number identifier corresponding to each field according to the bit number occupied by each field in the N fields;
The second typesetting module is used for typesetting the digit identification of each field and the field identification or the column identification corresponding to the field so as to obtain a field digit typesetting result;
And updating the second typesetting result according to the field digit typesetting result.
In an alternative embodiment, the apparatus further comprises a third determining module configured to:
Determining fixed file description data in the fund files, wherein the fixed file description data comprises data with the same type included in all the fund files represented by a financial data protocol adopted by the fund files;
the device further comprises a third typesetting module, which is used for performing EXCEL typesetting on the fixed file description data according to the typesetting format of the fixed file description data in the foundation file so as to obtain a third typesetting result aiming at the fixed file description data;
the device also comprises a third processing module which is used for generating an EXCEL file corresponding to the fund file according to the first typesetting result and the third typesetting result.
In an alternative embodiment, the apparatus further includes a verification module, after generating the EXCEL file corresponding to the fund file, for:
Receiving an editing operation for the EXCEL file;
determining a response result of the edited data in the EXCEL file to the editing operation according to the editing operation;
carrying out validity check on the response result according to the data attribute of the edited data, wherein the data attribute comprises the number of bits occupied by the data and/or the data retention level;
and if the test is not passed, the response to the editing operation is canceled.
In an alternative embodiment, the apparatus further comprises a conversion module for:
Determining an EXCEL file to be converted, wherein the EXCEL file to be converted is the EXCEL file obtained by conversion according to the foundation file;
performing typesetting conversion on the EXCEL file to be converted according to the typesetting format of the foundation file to obtain a fourth typesetting result;
and generating a fund file corresponding to the EXCEL file to be converted according to the fourth typesetting result.
In an alternative embodiment, the verification module is further configured to:
in the process of converting the EXCEL file to be converted into a corresponding fund file, carrying out validity check on key data, wherein the key data comprises at least one of field length, parameter number and data line number;
The conversion module is further configured to:
And when the key data passes the validity check, continuing to convert the EXCEL file to be converted into the corresponding fund file.
The advantages of the second aspect and the embodiments of the second aspect may be referred to the advantages of the first aspect and the embodiments of the first aspect, and will not be described here again.
In a third aspect, there is provided a computer device comprising:
A memory for storing program instructions;
And a processor for calling program instructions stored in the memory, and executing steps comprised in any one of the methods of the first aspect according to the obtained program instructions.
In a fourth aspect, there is provided a storage medium storing computer-executable instructions for causing a computer to perform the steps comprised in any one of the methods of the first aspect.
These and other aspects of the application will be more readily apparent from the following description of the embodiments.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings that are required to be used in the embodiments or the description of the prior art will be briefly described below, and it is obvious that the drawings in the following description are only embodiments of the present application, and that other drawings can be obtained according to the provided drawings without inventive effort for a person skilled in the art.
FIG. 1 is a diagram illustrating content of data files in a fund file according to an embodiment of the present application;
FIG. 2 is a schematic diagram of data content in a data file in a fund file according to an embodiment of the present application;
FIG. 3 is an interface schematic of a modifier in an embodiment of the application;
FIG. 4 is a schematic diagram of an interface for selectively opening ZIP files according to an embodiment of the present application;
FIG. 5 is a schematic diagram of an EXCLE file in an embodiment of the application;
FIG. 6 is a flowchart of a method for converting EXCLE files into foundation files in an embodiment of the application;
FIG. 7 is a flowchart of a method for processing a file according to an embodiment of the present application;
FIG. 8 is a schematic diagram of an arrangement of data contents of data files in a fund file according to an embodiment of the present application;
FIG. 9 is another schematic diagram illustrating an arrangement of data contents of data files in a fund file according to an embodiment of the present application;
FIG. 10 is a block diagram showing a structure of a document processing apparatus according to an embodiment of the present application;
FIG. 11 is a schematic diagram of a computer device according to an embodiment of the present application;
Fig. 12 is another schematic structural diagram of a computer device according to an embodiment of the present application.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the present application more apparent, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application, and it is apparent that the described embodiments are only some embodiments of the present application, not all embodiments of the present application. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application. Embodiments of the application and features of the embodiments may be combined with one another arbitrarily without conflict. Also, while a logical order is depicted in the flowchart, in some cases, the steps depicted or described may be performed in a different order than presented herein.
In order to facilitate understanding of the technical solution provided by the embodiments of the present application, a part of terms used in the embodiments of the present application are explained here:
1. the data exchange protocol of the open-type foundation business of the central data exchange platform prescribes data formats, data definitions and data contents used for data exchange between institutions in related business of asset management products (including but not limited to public offering foundation, non public offering foundation, aggregate asset management plan, etc., abbreviated herein as "foundation").
2. And the fund file is a file which complies with the data exchange protocol specification of the open fund business of the central data exchange platform, is called fund file for short and comprises a data index file and a data file. The naming rule of the data index file is 'OFI/OFJ/OFS/OFK/OFC "+ the code of the file creator +" _ "+ the code of the file receiver + the code of the file + the date (YYYYMMDD) +the TXT', and the naming rule of the data file is 'OFD" + "_" + the code of the file creator + the code of the file receiver + the date (YYYYMMDD) +the "_" + the two-bit file type code + ". TXT' content is the data content exchanged between the institutions.
3. A graphical user interface (GRAPHICAL USER INTERFACE, GUI) refers to a computer-operated user interface that is displayed graphically. A graphical user interface is an interface display format in which a person communicates with a computer, allowing a user to manipulate icons or menu options on a screen using an input device such as a mouse to select commands, invoke files, launch programs, or perform some other daily task.
4. Tkinter interface interfaces to standard Tk GUI toolkit for Python.
In addition, in the embodiment of the present application, the "plurality" may mean at least two, for example, two, three or more, and the embodiment of the present application is not limited. The term "and/or" is merely an association relationship describing the associated object, and means that three relationships may exist, for example, a and/or B may mean that a exists alone, while a and B exist together, and B exists alone. The character "/" herein generally indicates that the associated object is an "or" relationship unless otherwise specified.
In order to better understand the technical scheme provided by the embodiment of the present application, the technical background of the embodiment of the present application is described below.
In the prior art, referring to fig. 1, fig. 1 is a schematic diagram of a data file in an existing transaction fund file, the data file in the fund file is identified by 1 line of file start identifier, that is, OFDCFDAT,8 lines of fixed fields, each of the fixed fields includes a version number of open-type fund service data exchange protocol of the central data exchange platform, an information creator code, an information receiver code, a data date, a file transmission order flag, a file type, a sender, a receiver, that is, the number n of fields of lines 21, 03, 918, 20170106, 999, 04, 03, 918,1 in fig. 1, that is, the number of field of lines 116, n of field names in fig. 1, that is, the name of field App Sheet Serial No、Transaction Cfm Date、Currency Type、Confirmed Vol、Confirmed Amount、Fund Code、Large Rede mption Flag( in fig. 1, that is, only 8 field names in fig. 1, and the number of lines (m) of lines of 1 of line data content of 8, that is, only part of data content in line 8 in fig. 1, and the end identifier of file of line 1, that is, OFDCFEND.
Referring to fig. 2, fig. 2 is a diagram illustrating data contents of a data file in the transaction fund file shown in fig. 1, and it can be seen from the diagram that the first data content and the second data content each include a plurality of characters, and if the data file is only manually checked or processed, errors are easily generated.
In view of this, the inventors of the present application developed a modifier having a function of converting a fund file into an EXCEL file, which can be applied to a computer device. The modifier uses python development language and Tkinter interface, uses PYINSTALLER to package into exe executable file, thus, the user does not need to install python and other development integrated environments, and the use of the user is greatly facilitated.
Referring to fig. 3, a GUI interface of a modifier in the present application includes a tool log output area, where the tool log output area includes a time when a user uses the modifier and a specific content of an operation performed by the user, so that the user can quickly view a processing time and a specific processing procedure of a fund file, so that the user can clearly know the processing procedure of a working content of the fund file. Further, the tool log output area also includes a select file area and a function area, such as the functions of generating a file, opening xls files, opening zip files, and switching process files shown in fig. 3.
In the embodiment of the application, when the user uses the two functions, the corresponding file can be directly obtained by the function of opening xls file and the function of opening zip file displayed in the modifier GUI interface, namely, the two functions can enable the user to open the generated EXCLE file or the fund file without double clicking the file manager, but can open the corresponding file by clicking the functional button provided by the modifier, thereby reducing the operation steps of the user and improving the processing efficiency of the fund file.
In a specific implementation process, when the user selects to open the ZIP file function, please refer to fig. 4, a plurality of data files and data index files in the opened fund file may be displayed in the GUI interface of the modifier, and then the user may select to open one of the data files, for example, open the ofd_03_918_20170106_04.Txt data file as shown in fig. 4, the content of the data file may be seen, and the data content may be seen to be displayed partially because of the manner of splicing between fields, which makes it difficult for the user to read and modify. After the user performs the file generating operation on the aforementioned ofd_03_918_20170106_04.txt data file of the selected open fund file, please refer to fig. 5, fig. 5 is a GUI interface diagram for converting the data file fd_03_918_20170106_04.txt in the fund file into an EXCLE file.
In the embodiment of the application, the file switching function displayed in the modifier GUI interface can be easily and quickly switched between the functions of converting the fund file into the excel file and converting the excel file into the fund file when the user uses the function, so that the operation steps of the user are reduced, the time is saved, and the processing efficiency of the fund file is improved.
Further, referring to fig. 6, in a specific implementation process, the process of processing the fund file by using the modifier includes the following specific steps:
step 601, obtaining a selection operation for a foundation file to be processed.
Step 602, converting EXLCE the to-be-processed fund file into a file according to the selection operation.
Step 603, obtaining a processing operation of opening the xls file, and displaying the generated EX LCE file according to the processing operation.
Step 604, obtaining a modification or viewing operation for the displayed EXLCE file, and processing the EXLCE file according to the modification or viewing operation to obtain the target EXLCE file.
Step 605, obtaining a conversion operation for the target EXLCE file, and converting the target EXLCE file into a target fund file.
Step 606, obtaining an inspection operation for the target fund file to inspect the generated fund file.
As previously described, a user may use the modifier to convert a fund file into EXLCE files, then use the provided searching, hiding, etc. functions of EXLCE to quickly locate a certain field of a data file in the fund file, then perform checking or modifying on the field, etc. and also hide unnecessary fields. Further, after the value of a certain field in the EXLCE file is further modified, the EXLCE file can be converted into a fund file by using the switching processing file function of the modifier again.
The following describes the implementation principle of converting EXLCE a to-be-processed fund file in this embodiment in detail, please refer to fig. 7, fig. 7 is a flowchart of a file processing method in an embodiment of the present application.
Step 701, determining a fund file to be converted.
Step 702, reading transaction record data in a fund file, wherein the transaction record data comprises M pieces of sub-transaction data spliced according to a preset sequence, each piece of sub-transaction data in the M pieces of sub-transaction data comprises field data of N fields, the field names of each field in the N fields are different, and M and N are integers which are larger than or equal to 1.
In the embodiment of the present application, the method provided by the present application may be executed by the modifier, and specifically, the user clicks the foregoing fund file to determine the fund file to be converted.
When the modifier obtains the operation performed on the data file in the fund file, the modifier may obtain the data content in the data file, and in the embodiment of the present application, for convenience of description, the data content in the data file is referred to as transaction record data, where the transaction record data includes M pieces of sub-transaction data that are spliced in a predetermined order, each piece of sub-transaction data in the M pieces of sub-transaction data includes field data of N fields, and a field name of each field in the N fields is different.
For example, as shown in fig. 8, the transaction record data includes 3 pieces of sub-transaction record data, which are respectively the first sub-transaction record data, the second sub-transaction record data, and the third sub-transaction record data, and the first sub-transaction record data, the second sub-transaction record data, and the third sub-transaction record data include field 1, field 2, field 3, field 4, field 5, field 6, field 7, and field 8, respectively. With continued reference to fig. 8, the first sub-transaction record data is formed by concatenating data corresponding to field 1, field 2, field 3, field 4, field 5, field 6, field 7, and field 8, respectively. Further, the transaction record data may be formed by splicing the first sub-transaction record data, the second sub-transaction record data and the third sub-transaction record data. In addition, the first sub-transaction record data, the second sub-transaction record data, and the third sub-transaction in fig. 8 may be understood as the data contents in fig. 1.
In practical application, each piece of sub transaction record data includes a predetermined identifier, where the predetermined identifier is used to separate data between the sub transaction record data, and specifically, the predetermined identifier may be a space, or may be a x, or may be a #, which is not limited in the embodiment of the present application.
For example, as shown in fig. 9, the predetermined mark is a space, the transaction record data includes 3 pieces of sub transaction record data in total, which are respectively first sub transaction record data, second sub transaction record data and third sub transaction record data, and the first sub transaction record data, the second sub transaction record data and the third sub transaction record data include field 1, field 2, field 3, field 4 and field 5, respectively. With continued reference to fig. 9, the first sub-transaction record data may also be formed by concatenating the data corresponding to field 1, field 2, field 3, field 4, and field 5, and the second sub-transaction record data and the third sub-transaction record data may also be formed by concatenating the data corresponding to field 1, field 2, field 3, field 4, and field 5. A space is included between the first sub-transaction record data and the second sub-transaction record data, and a space is included between the second sub-transaction record data and the third sub-transaction record data. In this way, the first sub-transaction record data, the second sub-transaction record data, and the third sub-transaction record data can be clearly separated.
Step 703, dividing N fields of each piece of sub transaction data into N columns according to a typesetting format of the EXCEL file, and setting column identifications of the columns according to field names of the fields corresponding to each column to perform EXCEL typesetting so as to obtain a first typesetting result for the transaction record data;
In the embodiment of the application, after the transaction record data in the fund file is read, according to the typesetting format of the EXCEL file, N fields of each piece of sub transaction data are divided into N columns, and the EXCEL typesetting is performed by setting the column identification of the column according to the field name of the field corresponding to each column. That is, each piece of sub transaction data is composed of N fields which are spliced and arranged originally, each field occupies one column, and the transaction record data is typeset in a mode that each piece of sub transaction data occupies one row.
In a specific implementation process, taking the transaction record data as shown in fig. 4 as an example, according to the typesetting format of the EXCEL file, the transaction record data is divided into rows and columns to typeset the transaction record data, specifically, the division of each sub-transaction record data into rows may be performed according to the character length limitation of each field in the N fields, so that the typesetting result may be obtained. That is, the transaction record data is clearly displayed by the division manner of the rows and the columns, so that the user can accurately know the content of each field, and the accuracy of processing the fund file is enhanced.
And step 704, generating an EXCEL file corresponding to the foundation file according to the first typesetting result.
In the embodiment of the application, the EXCEL file corresponding to the fund file can be generated according to the first typesetting result obtained by dividing N fields of each piece of sub transaction data into N columns and setting the column identification of each column according to the field name of the field corresponding to each column.
That is, the field names included in the sub-transaction record data and the N columns of the typeset sub-transaction record data are arranged correspondingly, and then the transaction record data are processed in the manner described above, so that the EXCEL file corresponding to the fund file can be generated.
Referring to fig. 5 specifically, line 13 in the excel file shows the field name, and lines 14-18 show the transaction record data of the fund file, so that the user can clearly determine the content of the field, and thus can accurately view and/or modify the content of the field, and the processing efficiency of the fund file is improved.
Specifically, in one possible implementation manner, a target configuration file corresponding to the target fund file may be further determined, the field name of each field is determined from the target configuration file according to the field names of the N fields, and then the field names of the N fields are translated in a second language different from the first language to obtain N field identifiers represented in the second language, where the field names of the N fields in the first typesetting result are represented in the first language, for example, the first language of the field names is english, the second language may be chinese, german, french, portuguese, and other languages, that is, the N field identifiers represented in the second language may be a field identifier of chinese or a field identifier of french.
And setting N field identifiers expressed in a second language and N column identifiers in the first typesetting result as one column respectively according to the mode that the field identifiers used for expressing the same field name are correspondingly arranged with the column identifiers, so as to obtain a second typesetting result for the N fields. Further, an EXCEL file corresponding to the fund file may be generated according to the first typesetting result and the second typesetting result.
For example, referring to FIG. 5, the field identifier in the second language is converted to Chinese. In this way, users who are used to use different languages can know the field names clearly, and the user experience is improved.
Specifically, in one possible implementation manner, the bit number identifier corresponding to each field may be determined according to the bit number occupied by each field in the N fields, and then the bit number identifier of each field is typeset corresponding to the field identifier or the column identifier corresponding to the field, so as to obtain a field bit number typesetting result, and the second typesetting result is updated according to the field bit number typesetting result.
With continued reference to fig. 5, the field identifier of each field and the number of data bits of each field are in a column, so that the user can modify the data in a targeted manner when modifying the data, and the problem that the number of bits of modification is inconsistent with the protocol requirements is reduced as much as possible.
Specifically, in one possible implementation manner, fixed file description data in the fund file is determined, where the fixed file description data includes data with the same type included in all the fund files represented by the financial data protocol adopted by the fund file, and specifically, the fixed file description data may include a file identifier, a fixed record, a field name, and an end-of-file identifier. And then, according to the typesetting format of the fixed file description data in the fund file, performing EXCEL typesetting on the fixed file description data to obtain a third typesetting result aiming at the fixed file description data, so that the EXCEL file corresponding to the fund file can be generated according to the first typesetting result and the third typesetting result. Of course, in a specific implementation process, the EXCEL file corresponding to the fund file may also be generated according to the first typesetting result, the second typesetting result, and the third typesetting result.
In such a way, the generated EXCEL file corresponds to the foundation file, and the user can accurately use all data contents of the foundation file through the EXCEL file, so that the use experience of the user is improved.
Specifically, in one possible implementation, when the user wishes to modify or view the fund file, the user may perform a data modification operation in the EXCEL file after generating the EXCEL file corresponding to the fund file, and the computer device may receive an editing operation (e.g., modification) for the EXCEL file, and then determine a response result of the edited data in the EXCEL file to the editing operation according to the editing operation.
Further, after determining the response result of the edited data in the EXCEL file to the editing operation, the validity of the response result can be checked according to the data attribute of the edited data, wherein the data attribute comprises the number of bits occupied by the data and/or the data retention level, and when the check fails, the response to the editing operation is canceled.
In a specific implementation process, when a user modifies a certain field data in transaction record data in an EXCEL file, after determining a response result of edited data in the EXCEL file to the editing operation, the computer device may verify the field data according to the number of bits occupied by the data, and when the number of bits of the edited field data is different from the number of bits occupied by the field data (for example, the number of bits of the edited field data is greater than the number of bits occupied by the field or the number of bits of the edited field data is less than the number of bits occupied by the field), it may confirm that the verification is not passed, so that the response to the editing operation is cancelled, that is, the user finds that the modified field data is not displayed in the GUI interface.
In a specific implementation process, the data retention level may represent that the data may be deleted or not deleted when the file is converted, specifically, considering that the fixed file description data in the fund file is fixed and unchanged, the fixed file description data in the fund file may be determined to be low in retention level (data that may be deleted), and the transaction record data is determined to be high in retention level (data that may not be deleted).
When the data attribute of the edited data is transaction record data, if the number of the fields of the edited data is different from the number of the fields occupied by the data, for example, the number of the fields of the edited data is larger than the number of the fields occupied by the data, namely, the validity check is not passed, the response to the editing operation can be cancelled. In this way, the validity of the transaction record data can be accurately ensured.
In the embodiment of the application, when the user edits the EXCEL file, the user edited data can be checked to improve the accuracy of processing the file. When the verification fails, the response to the editing operation, that is, the illegal editing of the user is prevented during the editing operation, may be canceled to determine the validity of the edited data.
Specifically, in one possible implementation, the EXCEL file converted from the fund file may also be converted into the fund file. Specifically, an EXCEL file to be converted may be determined, where the EXCEL file to be converted is an EXCEL file converted from a foundation file. And then typesetting and converting the EXCEL file to be converted according to the typesetting format of the foundation file, so that a fourth typesetting result can be obtained, and the foundation file corresponding to the EXCEL file to be converted is generated according to the fourth typesetting result.
In such a way, the converted EXCEL file can be converted into the fund file again, so that a user can conveniently process transaction record data of the fund file in the EXCEL file, and then the processed EXCEL file is converted into the fund file, thereby improving user experience.
Specifically, in one possible implementation manner, the validity check may be further performed on the key data in the process of converting the EXCEL file to be converted into the corresponding fund file, where the key data includes at least one of a field length, a parameter number and a data line number, and when the validity check is performed on the key data, the conversion from the EXCEL file to be converted into the corresponding fund file may be continued.
In the embodiment of the application, the validity of the key data can be checked in the process of converting the EXCEL file to be converted into the corresponding fund file, so that the validity of the fund file converted from the EXCEL file can be further ensured, and the accuracy of file processing is improved.
Based on the same inventive concept, an embodiment of the present application provides a file processing device. The file processing means may be a hardware structure, a software module, or a hardware structure plus a software module. The document processing device may be implemented by a chip system, which may be formed by a chip, or may include a chip and other discrete devices. Referring to fig. 10, a file processing apparatus in an embodiment of the present application includes:
A first determining module 1001, configured to determine a fund file to be converted;
A reading module 1002, configured to read transaction record data in the fund file, where the transaction record data includes M pieces of sub-transaction data formed by splicing according to a predetermined order, each piece of sub-transaction data in the M pieces of sub-transaction data includes field data of N fields, field names of each field in the N fields are different, and M and N are integers greater than or equal to 1;
A first typesetting module 1003, configured to divide N fields of each piece of sub transaction data into N columns according to a typesetting format of an EXCEL file, and set a column identifier of each column according to a field name of a field corresponding to the column, so as to obtain a first typesetting result for the transaction record data;
and the first processing module 1004 is configured to generate an EXCEL file corresponding to the fund file according to the first typesetting result.
In an alternative embodiment, the file processing apparatus further includes a second determining module, configured to:
translating field names of the N fields in a second language different from the first language to obtain N field identifiers expressed in the second language, wherein the field names of the N fields in the first typesetting result are expressed in the first language;
The file processing device also comprises a second typesetting module, which is used for typesetting N field identifiers expressed in a second language and N column identifiers in the first typesetting result respectively into a column according to the mode that the field identifiers used for expressing the same field name are correspondingly arranged with the column identifiers so as to obtain a second typesetting result for the N fields;
The file processing device further comprises a second processing module, and the second processing module is used for generating an EXCEL file corresponding to the fund file according to the first typesetting result and the second typesetting result.
In an alternative embodiment, the second determining module is further configured to:
determining a bit number identifier corresponding to each field according to the bit number occupied by each field in the N fields;
The second typesetting module is used for typesetting the digit identification of each field and the field identification or the column identification corresponding to the field so as to obtain a field digit typesetting result;
and updating the second typesetting result according to the field bit typesetting result.
In an alternative embodiment, the file processing apparatus further includes a third determining module, configured to:
determining fixed file description data in the fund files, wherein the fixed file description data comprises data with the same type included in all the fund files represented by a financial data protocol adopted by the fund files;
The file processing device further comprises a third typesetting module, which is used for typesetting the fixed file description data according to the typesetting format of the fixed file description data in the foundation file so as to obtain a third typesetting result aiming at the fixed file description data;
The file processing device further comprises a third processing module, and the third processing module is used for generating an EXCEL file corresponding to the foundation file according to the first typesetting result and the third typesetting result.
In an alternative embodiment, the file processing device further includes a verification module, after generating the EXCEL file corresponding to the fund file, for:
receiving an editing operation for an EXCEL file;
Determining a response result of the edited data in the EXCEL file to the editing operation according to the editing operation;
carrying out validity check on the response result according to the data attribute of the edited data, wherein the data attribute comprises the bit number occupied by the data and/or the data retention level;
if the test fails, the response to the editing operation is revoked.
In an alternative embodiment, the file processing apparatus further includes a conversion module configured to:
Determining an EXCEL file to be converted, wherein the EXCEL file to be converted is the EXCEL file obtained by conversion according to the foundation file;
performing typesetting conversion on the EXCEL file to be converted according to the typesetting format of the foundation file to obtain a fourth typesetting result;
And generating a fund file corresponding to the EXCEL file to be converted according to the fourth typesetting result.
In an alternative embodiment, the verification module is further configured to:
in the process of converting an EXCEL file to be converted into a corresponding fund file, carrying out validity check on key data, wherein the key data comprises at least one of field length, parameter number and data line number;
the conversion module is also used for:
and when the key data passes the validity check, continuing to convert the EXCEL file to be converted into the corresponding fund file.
The division of the modules in the embodiments of the present application is schematically only one logic function division, and there may be another division manner in actual implementation, and in addition, each functional module in each embodiment of the present application may be integrated in one processor, or may exist separately and physically, or two or more modules may be integrated in one module. The integrated modules may be implemented in hardware or in software functional modules.
Based on the same inventive concept, the embodiment of the application also provides a computer device. As shown in fig. 11, the computer device in the embodiment of the present application includes at least one processor 1101, and a memory 1102 and a communication interface 1103 connected to the at least one processor 1101, and in the embodiment of the present application, a specific connection medium between the processor 1101 and the memory 1102 is not limited to the embodiment of the present application, and in fig. 11, the connection between the processor 1101 and the memory 1102 is taken as an example, and in fig. 11, the connection between the bus 1100 and other components is shown by a thick line, which is merely illustrative and not limiting. The bus 1100 may be divided into an address bus, a data bus, a control bus, etc., and is represented by only one thick line in fig. 11 for convenience of representation, but does not represent only one bus or one type of bus.
In an embodiment of the present application, the memory 1102 stores instructions executable by the at least one processor 1101, and the at least one processor 1101 can perform the steps included in the foregoing fault detection method by executing the instructions stored in the memory 1102.
The processor 1101 is a control center of a computer device, and may use various interfaces and lines to connect various parts of the entire fault detection device, and by executing or executing instructions stored in the memory 1102 and invoking data stored in the memory 1102, various functions of the computing device and processing the data, thereby overall monitoring the computing device. Alternatively, the processor 1101 may include one or more processing units, and the processor 1101 may integrate an application processor and a modem processor, wherein the processor 1101 primarily processes an operating system, a user interface, an application program, and the like, and the modem processor primarily processes wireless communications. It will be appreciated that the modem processor described above may not be integrated into the processor 1101. In some embodiments, the processor 1101 and the memory 1102 may be implemented on the same chip, and in some embodiments they may be implemented separately on separate chips.
The processor 1101 may be a general purpose processor such as a Central Processing Unit (CPU), digital signal processor, application specific integrated circuit, field programmable gate array or other programmable logic device, discrete gate or transistor logic device, discrete hardware components, which may implement or perform the methods, steps and logic blocks disclosed in embodiments of the application. The general purpose processor may be a microprocessor or any conventional processor or the like. The steps of a method disclosed in connection with the embodiments of the present application may be embodied directly in a hardware processor for execution, or in a combination of hardware and software modules in the processor for execution.
Memory 1102 is a non-volatile computer-readable storage medium that can be used to store non-volatile software programs, non-volatile computer-executable programs, and modules. The Memory 1102 may include at least one type of storage medium, and may include, for example, flash Memory, hard disk, multimedia card, card Memory, random access Memory (Random Access Memory, RAM), static random access Memory (Static Random Access Memory, SRAM), programmable Read-Only Memory (Programmable Read Only Memory, PROM), read-Only Memory (ROM), charged erasable programmable Read-Only Memory (ELECTRICALLY ERASABLE PROGRAMMABLE READ-Only Memory, EEPROM), magnetic Memory, magnetic disk, optical disk, and the like. Memory 1102 is any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer, but is not limited to such. The memory 1102 in embodiments of the present application may also be circuitry or any other device capable of performing memory functions for storing program instructions and/or data.
The communication interface 1103 is a transmission interface that can be used for communication, and data can be received or transmitted through the communication interface 1103.
With reference to the further structural schematic diagram of the computer device shown in fig. 12, the computer device further includes a basic input/output system (I/O system) 1201 to facilitate the transfer of information between various devices within the computer device, a mass storage device 1205 to store an operating system 1202, application programs 1203, and other program modules 1204.
The basic input/output system 1201 includes a display 1206 for displaying information, and an input device 1207, such as a mouse, keyboard, or the like, for user input of information. Wherein a display 1206 and an input device 1207 are coupled to the processor 1101 via a basic input/output system 1201 coupled to the system bus 1100. The basic input/output system 1201 may also include an input/output controller for receiving and processing input from a number of other devices, such as a keyboard, mouse, or electronic stylus. Similarly, the input-output controller also provides output to a display screen, a printer, or other type of output device.
The mass storage device 1205 is connected to the processor 1101 through a mass storage controller (not shown) that is connected to the system bus 1100. The mass storage device 1205 and its associated computer-readable media provide non-volatile storage for the server package. That is, the mass storage device 1205 may include a computer readable medium (not shown) such as a hard disk or CD-ROM drive.
According to various embodiments of the application, the computing device package may also be operated by a remote computer connected to the network through a network, such as the Internet. I.e., the computing device may connect to the network 1208 through a communication interface 1103 connected to the system bus 1100, or may connect to other types of networks or remote computer systems (not shown) using the communication interface 1103.
Based on the same inventive concept, embodiments of the present application also provide a computer-readable storage medium storing computer instructions that, when run on a computer, cause the computer to perform the steps of the order labeling method as described above.
Based on the same inventive concept, the embodiment of the application also provides a chip system, which comprises a processor and can also comprise a memory for realizing the steps of the file processing method. The chip system may be formed of a chip or may include a chip and other discrete devices.
In some possible implementations, aspects of the file processing method provided by the embodiments of the present application may also be implemented in the form of a program product including program code for causing a computer to perform the steps of the file processing method according to the various exemplary embodiments of the present application as described above when the program product is run on the computer.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, magnetic disk storage, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
It will be apparent to those skilled in the art that various modifications and variations can be made to the present application without departing from the spirit or scope of the application. Thus, it is intended that the present application also include such modifications and alterations insofar as they come within the scope of the appended claims or the equivalents thereof.

Claims (9)

1.一种文件处理方法,其特征在于,所述方法包括:1. A file processing method, characterized in that the method comprises: 确定待转换的基金文件;Identify the fund documents to be converted; 读取所述基金文件中的交易记录数据,其中,所述交易记录数据包括按照预定顺序拼接组成的M条子交易数据,所述M条子交易数据中的每条子交易数据均包括N个字段的字段数据,所述N个字段中的每个字段的字段名各不相同,M和N均为大于或等于1的整数;Reading the transaction record data in the fund file, wherein the transaction record data includes M pieces of sub-transaction data spliced in a predetermined order, each piece of the M pieces of sub-transaction data includes field data of N fields, each field name of the N fields is different, and M and N are both integers greater than or equal to 1; 按照EXCEL文件的排版格式,根据每条子交易数据的N个字段中每个字段的字符长度限制,将所述每条子交易数据划分为N列以及根据对应每列的字段的字段名设置该列的列标识进行EXCEL排版,以获得针对所述交易记录数据的第一排版结果;According to the typesetting format of the EXCEL file, according to the character length limit of each field in the N fields of each sub-transaction data, each sub-transaction data is divided into N columns, and a column identifier of the column is set according to the field name of the field corresponding to each column to perform EXCEL typesetting, so as to obtain a first typesetting result for the transaction record data; 根据所述N个字段中的每个字段所占据的位数,确定每个字段对应的位数标识;Determine a bit number identifier corresponding to each field according to the number of bits occupied by each field in the N fields; 将每个字段的位数标识与该字段对应的字段标识或列标识对应排版,以获得字段位数排版结果;根据所述第一排版结果和所述字段位数排版结果,生成与所述基金文件对应的EXCEL文件。The digit identifier of each field is arranged correspondingly with the field identifier or column identifier corresponding to the field to obtain a field digit layout result; based on the first layout result and the field digit layout result, an EXCEL file corresponding to the fund file is generated. 2.如权利要求1所述的方法,其特征在于,所述方法还包括:2. The method according to claim 1, characterized in that the method further comprises: 以不同于第一语种的第二语种对所述N个字段的字段名进行翻译,以得到以所述第二语种表示的N个字段标识,其中,所述第一排版结果中的所述N个字段的字段名以所述第一语种表示;Translating the field names of the N fields in a second language different from the first language to obtain N field identifiers expressed in the second language, wherein the field names of the N fields in the first typesetting result are expressed in the first language; 按照用于表示同一字段名的字段标识与列标识对应设置的方式,将以所述第二语种表示的N个字段标识分别与所述第一排版结果中的N个列标识对应设置为一列进行排版,以获得针对所述N个字段的第二排版结果;According to the manner of correspondingly setting the field identifier and the column identifier for representing the same field name, respectively setting the N field identifiers represented in the second language to correspond to the N column identifiers in the first typesetting result to form a column for typesetting, so as to obtain a second typesetting result for the N fields; 则,根据所述第一排版结果,生成与所述基金文件对应的EXCEL文件,包括:Then, according to the first typesetting result, an EXCEL file corresponding to the fund file is generated, including: 根据所述第一排版结果和所述第二排版结果,生成与所述基金文件对应的EXCEL文件。An EXCEL file corresponding to the fund file is generated according to the first typesetting result and the second typesetting result. 3.如权利要求1所述的方法,其特征在于,所述方法还包括:3. The method according to claim 1, characterized in that the method further comprises: 确定所述基金文件中的固定文件描述数据,其中,所述固定文件描述数据包括以所述基金文件所采用的金融数据协议所表示的所有基金文件中包括的类型相同的数据;Determining fixed file description data in the fund file, wherein the fixed file description data includes data of the same type included in all fund files represented by a financial data protocol adopted by the fund file; 根据所述固定文件描述数据在所述基金文件中的排版格式,对所述固定文件描述数据进行EXCEL排版,以获得针对所述固定文件描述数据的第三排版结果;According to the typesetting format of the fixed file description data in the fund file, performing EXCEL typesetting on the fixed file description data to obtain a third typesetting result for the fixed file description data; 则,根据所述第一排版结果,生成与所述基金文件对应的EXCEL文件,包括:Then, according to the first typesetting result, an EXCEL file corresponding to the fund file is generated, including: 根据所述第一排版结果和所述第三排版结果,生成与所述基金文件对应的EXCEL文件。An EXCEL file corresponding to the fund file is generated according to the first typesetting result and the third typesetting result. 4.如权利要求1所述的方法,其特征在于,在生成与所述基金文件对应的EXCEL文件之后,所述方法还包括:4. The method according to claim 1, characterized in that, after generating the EXCEL file corresponding to the fund file, the method further comprises: 接收针对所述EXCEL文件的编辑操作;Receiving an editing operation on the EXCEL file; 根据所述编辑操作,确定所述EXCEL文件中被编辑的数据对所述编辑操作的响应结果;According to the editing operation, determining a response result of the edited data in the EXCEL file to the editing operation; 根据所述被编辑的数据的数据属性对所述响应结果进行合法性校验;其中,所述数据属性包括数据所占位数和/或数据留存级别;Performing a validity check on the response result according to the data attributes of the edited data; wherein the data attributes include the number of bits occupied by the data and/or the data retention level; 若检验未通过,则撤销对所述编辑操作的响应。If the check fails, the response to the editing operation is canceled. 5.如权利要求1-4任一所述的方法,其特征在于,所述方法还包括:5. The method according to any one of claims 1 to 4, characterized in that the method further comprises: 确定待转换的EXCEL文件,其中,所述待转换的EXCEL文件是根据基金文件转换得到的EXCEL文件;Determine an EXCEL file to be converted, wherein the EXCEL file to be converted is an EXCEL file converted according to the fund file; 按照所述基金文件的排版格式,对所述待转换的EXCEL文件进行排版转换,以获得第四排版结果;Performing typesetting conversion on the EXCEL file to be converted according to the typesetting format of the fund file to obtain a fourth typesetting result; 根据所述第四排版结果,生成与所述待转换的EXCEL文件对应的基金文件。According to the fourth typesetting result, a fund file corresponding to the EXCEL file to be converted is generated. 6.如权利要求5所述的方法,其特征在于,所述方法还包括:6. The method according to claim 5, characterized in that the method further comprises: 在由所述待转换的EXCEL文件转换为对应的基金文件的过程中,对关键数据进行合法性检验;其中,所述关键数据包括字段长度、参数个数、数据行数中的至少一种;In the process of converting the EXCEL file to be converted into the corresponding fund file, the key data is subjected to a legality check; wherein the key data includes at least one of the field length, the number of parameters, and the number of data rows; 在所述关键数据进行合法性检验通过时,则继续进行由所述待转换的EXCEL文件到对应的基金文件的转换。When the key data passes the legality check, the conversion from the EXCEL file to be converted to the corresponding fund file will continue. 7.一种文件处理装置,其特征在于,所述装置包括:7. A file processing device, characterized in that the device comprises: 第一确定模块,用于确定待转换的基金文件;A first determination module, used to determine the fund file to be converted; 读取模块,用于读取所述基金文件中的交易记录数据,其中,所述交易记录数据包括按照预定顺序拼接组成的M条子交易数据,所述M条子交易数据中的每条子交易数据均包括N个字段的字段数据,所述N个字段中的每个字段的字段名各不相同,M和N均为大于或等于1的整数;a reading module, configured to read the transaction record data in the fund file, wherein the transaction record data includes M pieces of sub-transaction data spliced in a predetermined order, each piece of the M pieces of sub-transaction data includes field data of N fields, each field name of the N fields is different, and M and N are both integers greater than or equal to 1; 第一排版模块,用于按照EXCEL文件的排版格式,根据每条子交易数据的N个字段中每个字段的字符长度限制,将所述每条子交易数据划分为N列以及根据对应每列的字段的字段名设置该列的列标识进行EXCEL排版,以获得针对所述交易记录数据的第一排版结果;根据所述N个字段中的每个字段所占据的位数,确定每个字段对应的位数标识;将每个字段的位数标识与该字段对应的字段标识或列标识对应排版,以获得字段位数排版结果;A first typesetting module is used to divide each sub-transaction data into N columns according to the typesetting format of the EXCEL file and according to the character length limit of each field in the N fields of each sub-transaction data, and to set the column identifier of the column according to the field name of the field corresponding to each column for EXCEL typesetting, so as to obtain a first typesetting result for the transaction record data; determine the digit identifier corresponding to each field according to the number of digits occupied by each field in the N fields; and typeset the digit identifier of each field in correspondence with the field identifier or column identifier corresponding to the field, so as to obtain a field digit typesetting result; 第一处理模块,用于根据所述第一排版结果和所述字段位数排版结果,生成与所述基金文件对应的EXCEL文件。The first processing module is used to generate an EXCEL file corresponding to the fund file according to the first typesetting result and the field digit typesetting result. 8.一种计算机设备,其特征在于,所述计算机设备包括:8. A computer device, characterized in that the computer device comprises: 存储器,用于存储程序指令;A memory for storing program instructions; 处理器,用于调用所述存储器中存储的程序指令,按照获得的程序指令执行权利要求1-6任一所述的方法包括的步骤。A processor is used to call the program instructions stored in the memory, and execute the steps included in any one of the methods described in claims 1-6 according to the obtained program instructions. 9.一种存储介质,其特征在于,所述存储介质存储有计算机可执行指令,所述计算机可执行指令用于使计算机执行权利要求1-6任一所述的方法包括的步骤。9. A storage medium, characterized in that the storage medium stores computer executable instructions, and the computer executable instructions are used to enable a computer to execute the steps included in any one of the methods described in claims 1-6.
CN201910569703.9A 2019-06-27 2019-06-27 A file processing method, device and computer equipment Active CN110263316B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201910569703.9A CN110263316B (en) 2019-06-27 2019-06-27 A file processing method, device and computer equipment
PCT/CN2020/091378 WO2020259141A1 (en) 2019-06-27 2020-05-20 File processing method and apparatus, and computer device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910569703.9A CN110263316B (en) 2019-06-27 2019-06-27 A file processing method, device and computer equipment

Publications (2)

Publication Number Publication Date
CN110263316A CN110263316A (en) 2019-09-20
CN110263316B true CN110263316B (en) 2025-01-28

Family

ID=67922528

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910569703.9A Active CN110263316B (en) 2019-06-27 2019-06-27 A file processing method, device and computer equipment

Country Status (2)

Country Link
CN (1) CN110263316B (en)
WO (1) WO2020259141A1 (en)

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110263316B (en) * 2019-06-27 2025-01-28 深圳前海微众银行股份有限公司 A file processing method, device and computer equipment
CN110929485B (en) * 2019-12-06 2023-09-19 中国银联股份有限公司 File generation method, device, equipment and medium
CN111221738A (en) * 2020-01-10 2020-06-02 深圳前海环融联易信息科技服务有限公司 Data execution file generation method and device, computer equipment and storage medium
CN112037074B (en) * 2020-09-11 2024-04-19 中国银行股份有限公司 Visualization-based data file analysis method and device
CN114048939A (en) * 2021-09-26 2022-02-15 深圳市高腾科技服务有限公司 Escrow data cash checking method, device, equipment and storage medium for fund
CN115146608B (en) * 2022-05-13 2024-07-23 抖音视界有限公司 Content typesetting method, device, equipment and storage medium
CN118519977B (en) * 2024-06-03 2025-02-07 重庆赛力斯凤凰智创科技有限公司 Method and device for generating JSON file of vehicle data

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102279847A (en) * 2011-08-17 2011-12-14 瑞斯康达科技发展股份有限公司 Method and device for internationalizing software system
CN105117378A (en) * 2015-08-05 2015-12-02 联动优势电子商务有限公司 Method and apparatus for converting JSON file into EXCEL file

Family Cites Families (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000305954A (en) * 1999-04-09 2000-11-02 Hewlett Packard Co <Hp> Method for retrieving, updating, and storing data
CN103020024B (en) * 2012-12-27 2016-01-27 北京经纬恒润科技有限公司 A kind of file layout change-over method
CN103092993B (en) * 2013-02-18 2016-07-06 五八同城信息技术有限公司 Data export method and device
US10127209B2 (en) * 2015-11-24 2018-11-13 Bank Of America Corporation Transforming unstructured documents
CN106095992B (en) * 2016-06-21 2019-07-05 浪潮通用软件有限公司 Method for exchanging ERP data and Excel document data
US10691655B2 (en) * 2016-10-20 2020-06-23 Microsoft Technology Licensing, Llc Generating tables based upon data extracted from tree-structured documents
CN107291674A (en) * 2017-06-12 2017-10-24 广东川田卫生用品有限公司 A kind of method that Excel list datas are converted to database format
CN107341109B (en) * 2017-07-07 2021-07-16 中国银行股份有限公司 Test data generation method and system
CN107808003A (en) * 2017-11-14 2018-03-16 中国银行股份有限公司 A kind of document management method and device
CN109145268A (en) * 2018-08-22 2019-01-04 中国建设银行股份有限公司 A kind of document conversion method and device
CN109918343B (en) * 2019-03-25 2024-01-30 合芯科技(苏州)有限公司 Method and system for automatically generating ralf file
CN110263316B (en) * 2019-06-27 2025-01-28 深圳前海微众银行股份有限公司 A file processing method, device and computer equipment

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102279847A (en) * 2011-08-17 2011-12-14 瑞斯康达科技发展股份有限公司 Method and device for internationalizing software system
CN105117378A (en) * 2015-08-05 2015-12-02 联动优势电子商务有限公司 Method and apparatus for converting JSON file into EXCEL file

Also Published As

Publication number Publication date
WO2020259141A1 (en) 2020-12-30
CN110263316A (en) 2019-09-20

Similar Documents

Publication Publication Date Title
CN110263316B (en) A file processing method, device and computer equipment
CN111428462B (en) Communication protocol template construction method and terminal equipment
CN108292231B (en) Method and system for generating applications from data
US8010844B2 (en) File mutation method and system using file section information and mutation rules
CN111427561A (en) Service code generation method and device, computer equipment and storage medium
CN110414249B (en) Information processing method, information processing apparatus, storage medium, and electronic device
TW201439792A (en) System and method for accessing database
WO2022068556A1 (en) Code translation method and apparatus, and device
CN108073429A (en) A kind of means of payment collocation method, device, equipment and storage medium
CN114090671A (en) Data import method and device, electronic equipment and storage medium
CN112631924A (en) Automatic testing method and device, computer equipment and storage medium
CN112433705A (en) Script generation method and device, electronic equipment and storage medium
CN108710708A (en) Report processing method, device, medium and electronic equipment
CN111159040A (en) Test data generation method, device, equipment and storage medium
CN116775114A (en) Version library compatibility determining method and device, computer equipment and storage medium
CN116360769A (en) Code generation method, device, equipment and storage medium
CN117787153B (en) Hardware design verification method, device and storage medium
CN117667046B (en) Command analysis method, device, electronic equipment, storage medium and program product
CN114139502A (en) Document content processing method, device, device and storage medium
CN113705182A (en) Contract online generation method and device and readable storage medium
CN113901025A (en) Database management method, apparatus, device and storage medium
CN109948251B (en) CAD-based data processing method, device, equipment and storage medium
CN110377888B (en) HTML-based manuscript auditing editor real-time trace marking method and device
CN118051209A (en) Request parameter construction method, device, electronic device and storage medium
CN115599388A (en) API (application programming interface) document generation method, storage medium and electronic equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant