CN108415894A - Report data initial method, device, computer equipment and storage medium - Google Patents

Report data initial method, device, computer equipment and storage medium Download PDF

Info

Publication number
CN108415894A
CN108415894A CN201810214183.5A CN201810214183A CN108415894A CN 108415894 A CN108415894 A CN 108415894A CN 201810214183 A CN201810214183 A CN 201810214183A CN 108415894 A CN108415894 A CN 108415894A
Authority
CN
China
Prior art keywords
data
report
query result
script
xml format
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.)
Granted
Application number
CN201810214183.5A
Other languages
Chinese (zh)
Other versions
CN108415894B (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.)
Ping An Technology Shenzhen Co Ltd
Original Assignee
Ping An Technology Shenzhen 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 Ping An Technology Shenzhen Co Ltd filed Critical Ping An Technology Shenzhen Co Ltd
Priority to CN201810214183.5A priority Critical patent/CN108415894B/en
Publication of CN108415894A publication Critical patent/CN108415894A/en
Priority to PCT/CN2018/102610 priority patent/WO2019174191A1/en
Application granted granted Critical
Publication of CN108415894B publication Critical patent/CN108415894B/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/12Use of codes for handling textual entities
    • G06F40/14Tree-structured documents
    • G06F40/146Coding or compression of tree-structured data
    • 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/174Form filling; Merging
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • G06F16/2457Query processing with adaptation to user needs
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/248Presentation of query results
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/10Text processing
    • G06F40/12Use of codes for handling textual entities
    • G06F40/14Tree-structured documents
    • G06F40/143Markup, e.g. Standard Generalized Markup Language [SGML] or Document Type Definition [DTD]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/10Text processing
    • G06F40/12Use of codes for handling textual entities
    • G06F40/151Transformation

Abstract

This application discloses a kind of report data initial method, device, computer equipment and storage mediums.This method includes:The querying condition for obtaining typing corresponds to according to querying condition and obtains query result in source data table;It converts the query result to XML format query result data, middleware will be transmitted to after XML format query result data compression;Receive the data after dividing table fed back by middleware;Divide table sequence to sequentially produce data to be inserted into script according to data after table are divided;Data are inserted into report to be initiated after dividing table by data script, report after being initialized.This method is realized according to querying condition and selected inquiry database, and query statement is automatically generated, and being automatically inserted into report after automatic inquiry and returned data result is initialized, and manual processing is avoided, and is improved report and is initialized efficiency.

Description

Report data initial method, device, computer equipment and storage medium
Technical field
This application involves report data technical field more particularly to a kind of report data initial method, device, computers Equipment and storage medium.
Background technology
Report is exactly with formats such as table, charts come Dynamic Announce data.It can be formulated as:" report=various Format+dynamic data ".Currently, the initialization of report is to carry out initialization data manually, cause report initialization efficiency low Under.
Invention content
This application provides a kind of report data initial method, device, computer equipment and storage mediums, it is intended to solve The initialization of report is to carry out initialization data manually in the prior art, cause report initialize inefficiency the problem of.
In a first aspect, this application provides a kind of report data initial methods comprising:
The querying condition for obtaining typing corresponds to according to querying condition and obtains query result in source data table;
It converts the query result to XML format query result data, will be passed after XML format query result data compression Transport to middleware;
Receive the data after dividing table fed back by middleware;
Divide table sequence to sequentially produce data to be inserted into script according to data after table are divided;
Data are inserted into report to be initiated after dividing table by data script, report after being initialized.
Second aspect, this application provides a kind of report data apparatus for initializing comprising:
Query unit, the querying condition for obtaining typing are corresponded to obtain in source data table according to querying condition and be inquired As a result;
Format conversion unit looks into XML format for converting the query result to XML format query result data It is transmitted to middleware after asking result data compression;
Divide table receiving unit, for receiving the data after dividing table fed back by middleware;
Script generation unit, for according to dividing data after table to divide table sequence to sequentially produce data to be inserted into script;
Data interpolating unit is inserted into report to be initiated for passing through data after data script will divide table, obtains initial Report after change.
The third aspect, the application provide a kind of computer equipment again, including memory, processor and are stored in described deposit On reservoir and the computer program that can run on the processor, the processor realize this when executing the computer program Any one of them report data initial method provided is provided.
Fourth aspect, present invention also provides a kind of storage mediums, wherein the storage medium is stored with computer program, The computer program includes program instruction, and described program instruction makes the processor execute the application when being executed by a processor Any one of them report data initial method of offer.
A kind of report data initial method of the application offer, device, computer equipment and storage medium.This method passes through The querying condition for obtaining typing corresponds to according to querying condition and obtains query result in source data table;The query result is turned XML format query result data are turned to, middleware will be transmitted to after XML format query result data compression;It receives by middleware The data after dividing table fed back;Divide table sequence to sequentially produce data to be inserted into script according to data after table are divided;Pass through data script Data are inserted into report to be initiated after table will be divided, report after being initialized.This method is realized according to querying condition and selected Inquiry database to be selected, query statement is automatically generated, being automatically inserted into report after automatic inquiry and returned data result is initialized, Manual processing is avoided, report is improved and initializes efficiency.
Description of the drawings
It, below will be to needed in embodiment description in order to illustrate more clearly of the embodiment of the present application technical solution Attached drawing is briefly described, it should be apparent that, the accompanying drawings in the following description is some embodiments of the present application, general for this field For logical technical staff, without creative efforts, other drawings may also be obtained based on these drawings.
Fig. 1 is a kind of schematic flow diagram of report data initial method provided by the embodiments of the present application;
Fig. 2 is a kind of sub-process schematic diagram of report data initial method provided by the embodiments of the present application;
Fig. 3 is a kind of another sub-process schematic diagram of report data initial method provided by the embodiments of the present application;
Fig. 4 is a kind of another sub-process schematic diagram of report data initial method provided by the embodiments of the present application;
Fig. 5 is a kind of another schematic flow diagram of report data initial method provided by the embodiments of the present application;
Fig. 6 is a kind of schematic block diagram of report data apparatus for initializing provided by the embodiments of the present application;
Fig. 7 is a kind of subelement schematic block diagram of report data apparatus for initializing provided by the embodiments of the present application;
Fig. 8 is a kind of another subelement schematic block diagram of report data apparatus for initializing provided by the embodiments of the present application;
Fig. 9 is a kind of another subelement schematic block diagram of report data apparatus for initializing provided by the embodiments of the present application;
Figure 10 is a kind of another schematic block diagram of report data apparatus for initializing provided by the embodiments of the present application;
Figure 11 is a kind of schematic block diagram of computer equipment provided by the embodiments of the present application.
Specific implementation mode
Below in conjunction with the attached drawing in the embodiment of the present application, technical solutions in the embodiments of the present application carries out clear, complete Site preparation describes, it is clear that described embodiment is some embodiments of the present application, instead of all the embodiments.Based on this Shen Please in embodiment, every other implementation obtained by those of ordinary skill in the art without making creative efforts Example, shall fall in the protection scope of this application.
It should be appreciated that ought use in this specification and in the appended claims, term " comprising " and "comprising" instruction Described feature, entirety, step, operation, the presence of element and/or component, but one or more of the other feature, whole is not precluded Body, step, operation, element, component and/or its presence or addition gathered.
It is also understood that the term used in this present specification is merely for the sake of the mesh for describing specific embodiment And be not intended to limit the application.As present specification and it is used in the attached claims, unless on Other situations are hereafter clearly indicated, otherwise " one " of singulative, "one" and "the" are intended to include plural form.
It will be further appreciated that the term "and/or" used in present specification and the appended claims is Refer to any combinations and all possible combinations of one or more of associated item listed, and includes these combinations.
Referring to Fig. 1, Fig. 1 is a kind of schematic flow diagram of report data initial method provided by the embodiments of the present application. This method is applied in the terminals such as desktop computer, laptop computer, tablet computer.As shown in Figure 1, the method comprising the steps of S101~ S105。
S101, the querying condition for obtaining typing, correspond to according to querying condition and obtain query result in source data table.
In the present embodiment, on the interface that pre-set report initializes tool, typing querying condition and source data After the database (can be regarded as source data table) stored, query result can be obtained in source data table according to querying condition.
For example, in order to count the business conclusion of the business situation of certain company business personnel of in August, 2017, tool can be initialized in report Interface on typing inquiry business conclusion of the business timing statistics 201708, by 201708, (querying condition can be regarded as querying conditions A certain row name in source data table).At this point, can also typing source data table is stored on interface database (source data table institute The database of storage can be regarded as inquiry library), the path of source data table and title (title of source data table can be regarded as table name, The path of source data table can be regarded as subregion namely which subregion source data table is stored in), after completing above-mentioned typing, i.e., Can data quickly be inquired according to querying condition in the source data table in inquiry library.
S102, the query result is converted to XML format query result data, by XML format query result data pressure Middleware is transmitted to after contracting.
In the present embodiment, it converts the query result to XML format, is to improve the readability of data and can expand Malleability, and the data of XML format are label forms.It can be than simple binary number although converting query result to XML format According to larger, but it ensure that data good readable and scalability, application range are wider.And XML format is inquired and is tied When fruit is transmitted to middleware, need to carry out data compression, to improve transmission rate.
In one embodiment, as shown in Fig. 2, the step S102 includes following sub-step:
S1021, the query result is converted to XML format query result data by WriteXML classes;
S1022, compressed after encoding XML format query result data by Base64 after data, will Data transmission is to middleware after compression.
In the present embodiment, the syntax format of WriteXML classes is as follows:
writexml(writer,indent,addindent,newl,encoding);
Wherein, writer is file object;
Indent is the character filled before each tag, such as:' ', then it represents that there are two spaces before each tag;
Addindent is the nearly character of contracting of each child node;
Newl is the character filled after each tag, such as:' n', then it represents that there are one carriage returns behind each tag;
Encoding is the encoding attribute values in the XML information head generated;
Writexml methods are other than writer parameters must have, remaining can be omitted.
After converting query result to XML format query result data by WriteXML classes, the readability of data is improved And scalability, and the data of XML format are label forms.
It is and to ensure number in order to which data are done simple compression after being encoded by Base64 to XML format query result data Less bandwidth is occupied when according to transmission.Base64 is a kind of coding mode, commonly used in being writeable binary data coding The data of character style.This is a kind of reversible coding mode.Data after coding are a character string, character wherein included For A-Z, a-z, 0-9 ,+,/totally 64 characters (26+26+10+1+1=64).It completes to XML format query result data Base64 is encoded, and is achieved that compressing data, and improve its Information Security.
The data after dividing table that S103, reception are fed back by middleware.
In one embodiment, as shown in figure 3, the step S103 includes following sub-step:
S1031, data and Base64 decodings are carried out after receiving compression, obtains decompression data;
S1032, the gauge outfit decompressed in data is obtained, is grouped, is obtained with gauge outfit one by one by data are decompressed according to gauge outfit Correspondence divides the data after table.
In the present embodiment, data and Base64 decodings are carried out after middleware, which receives, to be compressed, obtains decompression data, namely Reduce XML format query result data.It is grouped, is obtained and gauge outfit by data are decompressed according to gauge outfit in middleware at this time One-to-one correspondence divides the data after table.That is, by the middleware being connect with database where source data table, it can be quickly to data A point list processing is carried out, raising divides table efficiency.
Wherein, middleware is a middleware for providing relevant database Distributed Services, can allow traditional number Behavior extension is carried out according to type and seems a still database, realizes the Multi-function extension of database.
Wherein, gauge outfit is equivalent to a data type identifier, such as gauge outfit 1 indicates first kind business datum (such as Personal risk business datum), gauge outfit 2 indicate Second Type business datum (such as group danger business datum).By gauge outfit in middleware A point table is carried out to data in system, it can be more quick.
S104, according to dividing data after table to divide table sequence to sequentially produce data to be inserted into script.
In one embodiment, as shown in figure 4, the step S104 includes following sub-step:
S1041, it obtains divide in the data after table the first business datum table to N business datum tables respectively;Wherein N is just whole Number;
S1042, the first business datum table data are automatically generated according to included each data in the first business datum table It is inserted into script, automatically generating the second business datum table data according to included each data in the second business datum table is inserted into foot This, until being inserted into foot according to N business datum table data are automatically generated according to included each data in N business datum tables This.
In the present embodiment, due to having carried out dividing table to data according to gauge outfit, that is, there are multiple business datum tables, this is more Business datum table is to be classified according to business, therefore to be inserted into script be suitable according to the arrangement of multiple traffic tables automatically generating Sequence sequentially generates, such as corresponds to generate according to every data of business datum table 1 and be inserted into script, and will be counted by being inserted into script Report is specified according to being inserted into, and so on, the data of last business datum table are directly passed through into the insertion script that automatically generates It is inserted into and specifies report.The insertion script automatically generated can be sequentially generated according to the data arrangement sequence in first traffic table successively Insertion script in first traffic table per data sequentially generates second according to the data arrangement sequence in second traffic table It opens the insertion script in traffic table per data and is opened until sequentially generating N according to the data arrangement sequence in N traffic tables Insertion script in traffic table per data, wherein N are positive integer.By automatically generating automatic insert respectively according to each data Enter script, is achieved that data, which are inserted into report, to be initialized without user's manual operations.
S105, will divide table by data script after data be inserted into report to be initiated, report after being initialized.
In one embodiment, as shown in figure 5, further including step after the step S105:
S106, query result is shown with query result display area in the displaying table corresponding to report after initialization Show, data, which are inserted into script script display area in displaying table, to be shown.
In the present embodiment, in order to more intuitively see each query result, and it is corresponding with each query result Data be inserted into script, can by by query result with query result display area in the displaying table corresponding to report after initialization It is shown, data, which are inserted into script script display area in displaying table, to be shown.In this way, when user is in the report of initialization When sending out available data in table in the presence of mistake, corresponding inquiry data can be found by the query result display area of above-mentioned display, and It finds corresponding data and is inserted into script and directly modify adjustment, improve the efficiency of error correction.
As it can be seen that this method is realized according to querying condition and selected inquiry database, query statement is automatically generated, is looked into automatically It askes and is automatically inserted into report after returned data result and initialized, avoid manual processing, improve report and initialize efficiency.
The embodiment of the present application also provides a kind of report data apparatus for initializing, and the report data apparatus for initializing is for executing Any one of aforementioned report data initial method.Specifically, referring to Fig. 6, Fig. 6 is a kind of report provided by the embodiments of the present application The schematic block diagram of data initialization device.Report data apparatus for initializing 100 can be installed on desktop computer, tablet computer, Laptop computer, etc. in terminals.
As shown in fig. 6, report data apparatus for initializing 100 includes query unit 101, format conversion unit 102, table is divided to connect Receive unit 103, script generation unit 104 and data interpolating unit 105.
Query unit 101, the querying condition for obtaining typing are obtained in source data table according to querying condition correspondence and are looked into Ask result.
In the present embodiment, on the interface that pre-set report initializes tool, typing querying condition and source data After the database (can be regarded as source data table) stored, query result can be obtained in source data table according to querying condition.
For example, in order to count the business conclusion of the business situation of certain company business personnel of in August, 2017, tool can be initialized in report Interface on typing inquiry business conclusion of the business timing statistics 201708, by 201708, (querying condition can be regarded as querying conditions A certain row name in source data table).At this point, can also typing source data table is stored on interface database (source data table institute The database of storage can be regarded as inquiry library), the path of source data table and title (title of source data table can be regarded as table name, The path of source data table can be regarded as subregion namely which subregion source data table is stored in), after completing above-mentioned typing, i.e., Can data quickly be inquired according to querying condition in the source data table in inquiry library.
Format conversion unit 102, for converting the query result to XML format query result data, by XML format It is transmitted to middleware after query result data compression.
In the present embodiment, it converts the query result to XML format, is to improve the readability of data and can expand Malleability, and the data of XML format are label forms.It can be than simple binary number although converting query result to XML format According to larger, but it ensure that data good readable and scalability, application range are wider.And XML format is inquired and is tied When fruit is transmitted to middleware, need to carry out data compression, to improve transmission rate.
In one embodiment, as shown in fig. 7, the format conversion unit 102 includes following subelement:
Data type conversion unit 1021 is looked into for converting the query result to XML format by WriteXML classes Ask result data;
Compression unit 1022 is pressed for being compressed after encoding XML format query result data by Base64 Data after contracting, by data transmission after compression to middleware.
In the present embodiment, the syntax format of WriteXML classes is as follows:
writexml(writer,indent,addindent,newl,encoding);
Wherein, writer is file object;
Indent is the character filled before each tag, such as:' ', then it represents that there are two spaces before each tag;
Addindent is the nearly character of contracting of each child node;
Newl is the character filled after each tag, such as:' n', then it represents that there are one carriage returns behind each tag;
Encoding is the encoding attribute values in the XML information head generated;
Writexml methods are other than writer parameters must have, remaining can be omitted.
After converting query result to XML format query result data by WriteXML classes, the readability of data is improved And scalability, and the data of XML format are label forms.
It is and to ensure number in order to which data are done simple compression after being encoded by Base64 to XML format query result data Less bandwidth is occupied when according to transmission.Base64 is a kind of coding mode, commonly used in being writeable binary data coding The data of character style.This is a kind of reversible coding mode.Data after coding are a character string, character wherein included For A-Z, a-z, 0-9 ,+,/totally 64 characters (26+26+10+1+1=64).It completes to XML format query result data Base64 is encoded, and is achieved that compressing data, and improve its Information Security.
Divide table receiving unit 103, for receiving the data after dividing table fed back by middleware.
In one embodiment, as shown in figure 8, described divide table receiving unit 103 to include following subelement:
Decompression units 1031 for data after reception compression and carry out Base64 decodings, obtain decompression data;
Grouped element 1032 is grouped data are decompressed according to gauge outfit, obtains for obtaining the gauge outfit in decompression data The data after dividing table are corresponded with gauge outfit.
In the present embodiment, data and Base64 decodings are carried out after middleware, which receives, to be compressed, obtains decompression data, namely Reduce XML format query result data.It is grouped, is obtained and gauge outfit by data are decompressed according to gauge outfit in middleware at this time One-to-one correspondence divides the data after table.That is, by the middleware being connect with database where source data table, it can be quickly to data A point list processing is carried out, raising divides table efficiency.
Wherein, middleware is a middleware for providing relevant database Distributed Services, can allow traditional number Behavior extension is carried out according to type and seems a still database, realizes the Multi-function extension of database.
Wherein, gauge outfit is equivalent to a data type identifier, such as gauge outfit 1 indicates first kind business datum (such as Personal risk business datum), gauge outfit 2 indicate Second Type business datum (such as group danger business datum).By gauge outfit in middleware A point table is carried out to data in system, it can be more quick.
Script generation unit 104, for according to dividing data after table to divide table sequence to sequentially produce data to be inserted into script.
In one embodiment, as shown in figure 9, the script generation unit 104 includes following subelement:
Point table acquiring unit 1041, for obtaining in the data after point table the first business datum table respectively to N business numbers According to table;Wherein N is positive integer;
It is inserted into script acquiring unit 1042, for being automatically generated according to included each data in the first business datum table First business datum table data are inserted into script, and the second industry is automatically generated according to included each data in the second business datum table Business data table data is inserted into script, until automatically generating N industry according to according to included each data in N business datum tables Business data table data is inserted into script.
In the present embodiment, due to having carried out dividing table to data according to gauge outfit, that is, there are multiple business datum tables, this is more Business datum table is to be classified according to business, therefore to be inserted into script be suitable according to the arrangement of multiple traffic tables automatically generating Sequence sequentially generates, such as corresponds to generate according to every data of business datum table 1 and be inserted into script, and will be counted by being inserted into script Report is specified according to being inserted into, and so on, the data of last business datum table are directly passed through into the insertion script that automatically generates It is inserted into and specifies report.The insertion script automatically generated can be sequentially generated according to the data arrangement sequence in first traffic table successively Insertion script in first traffic table per data sequentially generates second according to the data arrangement sequence in second traffic table It opens the insertion script in traffic table per data and is opened until sequentially generating N according to the data arrangement sequence in N traffic tables Insertion script in traffic table per data, wherein N are positive integer.By automatically generating automatic insert respectively according to each data Enter script, is achieved that data, which are inserted into report, to be initialized without user's manual operations.
Data interpolating unit 105 is inserted into report to be initiated for passing through data after data script will divide table, obtains just Report after beginningization.
In one embodiment, as shown in Figure 10, the report data apparatus for initializing 100 further includes:
Display unit 106, for showing query result with query result in the displaying table corresponding to report after initialization Show that region is shown, data, which are inserted into script script display area in displaying table, to be shown.
In the present embodiment, in order to more intuitively see each query result, and it is corresponding with each query result Data be inserted into script, can by by query result with query result display area in the displaying table corresponding to report after initialization It is shown, data, which are inserted into script script display area in displaying table, to be shown.In this way, when user is in the report of initialization When sending out available data in table in the presence of mistake, corresponding inquiry data can be found by the query result display area of above-mentioned display, and It finds corresponding data and is inserted into script and directly modify adjustment, improve the efficiency of error correction.
As it can be seen that the device is realized according to querying condition and selected inquiry database, query statement is automatically generated, is looked into automatically It askes and is automatically inserted into report after returned data result and initialized, avoid manual processing, improve report and initialize efficiency.
Above-mentioned report data apparatus for initializing can be implemented as a kind of form of computer program, which can be with It is run on computer equipment as shown in figure 11.
Please refer to Fig.1 the schematic block diagram that 1, Figure 11 is a kind of computer equipment provided by the embodiments of the present application.The calculating 500 equipment of machine equipment can be terminal.The terminal can be tablet computer, laptop, desktop computer, personal digital assistant Equal electronic equipments.
Refering to fig. 11, which includes processor 502, memory and the net connected by system bus 501 Network interface 505, wherein memory may include non-volatile memory medium 503 and built-in storage 504.
The non-volatile memory medium 503 can storage program area 5031 and computer program 5032.The computer program 5032 include program instruction, which is performed, and processor 502 may make to execute a kind of report data initialization side Method.
The processor 502 supports the operation of entire computer equipment 500 for providing calculating and control ability.
The built-in storage 504 provides environment for the operation of the computer program 5032 in non-volatile memory medium 503, should When computer program 5032 is executed by processor 502, processor 502 may make to execute a kind of report data initial method.
The network interface 505 such as sends the task dispatching of distribution for carrying out network communication.Those skilled in the art can manage It solves, structure is not constituted only with the block diagram of the relevant part-structure of application scheme to the application side shown in Figure 11 The restriction for the computer equipment 500 that case is applied thereon, specific computer equipment 500 may include more than as shown in the figure Or less component, it either combines certain components or is arranged with different components.
Wherein, the processor 502 is for running computer program 5032 stored in memory, to realize following work( Energy:The querying condition for obtaining typing corresponds to according to querying condition and obtains query result in source data table;By the query result XML format query result data are converted into, middleware will be transmitted to after XML format query result data compression;It receives by centre What part was fed back divides data after table;Divide table sequence to sequentially produce data to be inserted into script according to data after table are divided;Pass through data pin Data are inserted into report to be initiated after this will divide table, report after being initialized.
In one embodiment, processor 502 also executes following operation:The query result is converted by WriteXML classes For XML format query result data;It is compressed after obtaining compression after XML format query result data are encoded by Base64 Data, by data transmission after compression to middleware.
In one embodiment, processor 502 also executes following operation:It receives data after compressing and carries out Base64 decodings, Obtain decompression data;The gauge outfit in decompression data is obtained, is grouped according to gauge outfit by data are decompressed, is obtained a pair of with gauge outfit one The data after table should be divided.
In one embodiment, processor 502 also executes following operation:The first business number in the data after dividing table is obtained respectively According to table to N business datum tables;Wherein N is positive integer;It is given birth to automatically according to included each data in the first business datum table It is inserted into script at the first business datum table data, second is automatically generated according to included each data in the second business datum table Business datum table data are inserted into script, until automatically generating N according to according to included each data in N business datum tables Business datum table data are inserted into script.
In one embodiment, processor 502 also executes following operation:By query result with corresponding to report after initialization Displaying table in query result display area shown that data, which are inserted into script script display area in displaying table, to be shown Show.
It will be understood by those skilled in the art that the embodiment of computer equipment shown in Figure 11 is not constituted to computer The restriction of equipment specific composition, in other embodiments, computer equipment may include components more more or fewer than diagram, or Person combines certain components or different components arrangement.For example, in some embodiments, computer equipment can only include depositing Reservoir and processor, in such embodiments, the structure and function of memory and processor are consistent with embodiment illustrated in fig. 11, Details are not described herein.
It should be appreciated that in the embodiment of the present application, processor 502 can be central processing unit (Central Processing Unit, CPU), which can also be other general processors, digital signal processor (Digital Signal Processor, DSP), application-specific integrated circuit (Application Specific Integrated Circuit, ASIC), ready-made programmable gate array (Field-Programmable GateArray, FPGA) or other programmable logic devices Part, discrete gate or transistor logic, discrete hardware components etc..Wherein, general processor can be microprocessor or The processor can also be any conventional processor etc..
A kind of storage medium is provided in another embodiment of the application.The storage medium can be computer-readable storage Medium.The storage medium is stored with computer program, and wherein computer program includes program instruction.The program instruction is by processor It is realized when execution:The querying condition for obtaining typing corresponds to according to querying condition and obtains query result in source data table;It will be described Query result is converted into XML format query result data, will be transmitted to middleware after XML format query result data compression;It connects Receive the data after dividing table fed back by middleware;Divide table sequence to sequentially produce data to be inserted into script according to data after table are divided;It is logical Data are inserted into report to be initiated after crossing data script and dividing table, report after being initialized.
In one embodiment, it is realized when which is executed by processor:The query result is passed through into WriteXML Class is converted into XML format query result data;It is compressed to obtain after XML format query result data are encoded by Base64 Data after compression, by data transmission after compression to middleware.
In one embodiment, it is realized when which is executed by processor:It receives data after compressing and carries out Base64 Decoding obtains decompression data;The gauge outfit in decompression data is obtained, is grouped, is obtained and gauge outfit by data are decompressed according to gauge outfit One-to-one correspondence divides the data after table.
In one embodiment, it is realized when which is executed by processor:It obtains respectively first in the data after dividing table Business datum table is to N business datum tables;Wherein N is positive integer;According to included each data in the first business datum table It automatically generates the first business datum table data and is inserted into script, given birth to automatically according to included each data in the second business datum table It is inserted into script at the second business datum table data, until according to automatic according to included each data in N business datum tables It generates N business datum table data and is inserted into script.
In one embodiment, it is realized when which is executed by processor:By query result with report after initialization Query result display area is shown in corresponding displaying table, and data are inserted into script script display area in showing table It is shown.
The storage medium can be the internal storage unit of aforementioned device, such as the hard disk or memory of equipment.It is described to deposit Storage media can also be the plug-in type hard disk being equipped on the External memory equipment of the equipment, such as the equipment, intelligent storage Block (Smart Media Card, SMC), secure digital (Secure Digital, SD) card, flash card (Flash Card) etc.. Further, the storage medium can also both include the equipment internal storage unit and also including External memory equipment.
It is apparent to those skilled in the art that for convenience of description and succinctly, foregoing description is set The specific work process of standby, device and unit, can refer to corresponding processes in the foregoing method embodiment, and details are not described herein. Those of ordinary skill in the art may realize that units and algorithm described in conjunction with the examples disclosed in the embodiments of the present disclosure Step can be realized with electronic hardware, computer software, or a combination of the two, in order to clearly demonstrate hardware and software Interchangeability generally describes each exemplary composition and step according to function in the above description.These functions are studied carefully Unexpectedly the specific application and design constraint depending on technical solution are implemented in hardware or software.Professional technician Each specific application can be used different methods to achieve the described function, but this realization is it is not considered that exceed The scope of the present invention.
In several embodiments provided herein, it should be understood that disclosed unit and method, it can be with It realizes by another way.For example, the apparatus embodiments described above are merely exemplary, for example, the unit It divides, only a kind of division of logic function, formula that in actual implementation, there may be another division manner can also will have identical work( The unit set of energy can be combined or can be integrated into another system at a unit, such as multiple units or component, or Some features can be ignored or not executed.In addition, shown or discussed mutual coupling or direct-coupling or communication link It can be INDIRECT COUPLING or communication connection by some interfaces, device or unit to connect, and can also be electricity, mechanical or other Form connection.
The unit illustrated as separating component may or may not be physically separated, aobvious as unit The component shown may or may not be physical unit, you can be located at a place, or may be distributed over multiple In network element.Some or all of unit therein can be selected according to the actual needs to realize the embodiment of the present invention Purpose.
In addition, each functional unit in each embodiment of the present invention can be integrated in a processing unit, it can also It is that each unit physically exists alone, can also be during two or more units are integrated in one unit.It is above-mentioned integrated The form that hardware had both may be used in unit is realized, can also be realized in the form of SFU software functional unit.
If the integrated unit is realized in the form of SFU software functional unit and sells or use as independent product When, it can be stored in a storage medium.Based on this understanding, technical scheme of the present invention is substantially in other words to existing The all or part of part or the technical solution that technology contributes can be expressed in the form of software products, should Computer software product is stored in a storage medium, including some instructions are used so that a computer equipment (can be Personal computer, server or network equipment etc.) execute all or part of step of each embodiment the method for the present invention Suddenly.And storage medium above-mentioned includes:USB flash disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), magnetic disc or The various media that can store program code such as person's CD.
The above description is merely a specific embodiment, but scope of protection of the present invention is not limited thereto, any Those familiar with the art in the technical scope disclosed by the present invention, can readily occur in various equivalent modifications or replace It changes, these modifications or substitutions should be covered by the protection scope of the present invention.Therefore, protection scope of the present invention should be with right It is required that protection domain subject to.

Claims (10)

1. a kind of report data initial method, which is characterized in that including:
The querying condition for obtaining typing corresponds to according to querying condition and obtains query result in source data table;
It converts the query result to XML format query result data, will be transmitted to after XML format query result data compression Middleware;
Receive the data after dividing table fed back by middleware;
Divide table sequence to sequentially produce data to be inserted into script according to data after table are divided;
Data are inserted into report to be initiated after dividing table by data script, report after being initialized.
2. report data initial method according to claim 1, which is characterized in that described to convert the query result For XML format query result data, it will be transmitted to middleware after XML format query result data compression, including:
It converts the query result to XML format query result data by WriteXML classes;
Data after being compressed after XML format query result data are encoded by Base64, by data after compression It is transmitted to middleware.
3. report data initial method according to claim 2, which is characterized in that the reception is fed back by middleware Data after dividing table, including:
It receives data after compressing and carries out Base64 decodings, obtain decompression data;
The gauge outfit in decompression data is obtained, is grouped according to gauge outfit by data are decompressed, is obtained after dividing table with gauge outfit one-to-one correspondence Data.
4. report data initial method according to claim 3, which is characterized in that the basis divides point of data after table Table sequence sequentially produces data and is inserted into script, including:
It obtains respectively and divides in the data after table the first business datum table to N business datum tables;Wherein N is positive integer;
The first business datum table data, which are automatically generated, according to included each data in the first business datum table is inserted into script, root The second business datum table data are automatically generated according to included each data in the second business datum table and are inserted into script, until basis N business datum table data, which are automatically generated, according to included each data in N business datum tables is inserted into script.
5. according to claim 1-4 any one of them report data initial methods, which is characterized in that described to pass through data pin Data are inserted into report to be initiated after this will divide table, after being initialized after report, further include:
Query result is shown with query result display area in the displaying table corresponding to report after initialization, by data Script script display area in displaying table is inserted into be shown.
6. a kind of report data apparatus for initializing, which is characterized in that including:
Query unit, the querying condition for obtaining typing correspond to according to querying condition and obtain query result in source data table;
XML format is inquired and is tied for converting the query result to XML format query result data by format conversion unit It is transmitted to middleware after fruit data compression;
Divide table receiving unit, for receiving the data after dividing table fed back by middleware;
Script generation unit, for according to dividing data after table to divide table sequence to sequentially produce data to be inserted into script;
Data interpolating unit is inserted into report to be initiated, after obtaining initialization for passing through data after data script will divide table Report.
7. report data apparatus for initializing according to claim 6, which is characterized in that the format conversion unit, including:
Data type conversion unit, for converting the query result to XML format query result number by WriteXML classes According to;
Compression unit, for data after being compressed after encoding XML format query result data by Base64, By data transmission after compression to middleware.
8. report data apparatus for initializing according to claim 7, which is characterized in that it is described to divide table receiving unit, including:
Decompression units for data after reception compression and carry out Base64 decodings, obtain decompression data;
Grouped element is grouped data are decompressed according to gauge outfit, obtains and gauge outfit one for obtaining the gauge outfit in decompression data One correspondence divides the data after table.
9. a kind of computer equipment, including memory, processor and it is stored on the memory and can be on the processor The computer program of operation, which is characterized in that the processor is realized when executing the computer program as in claim 1-5 Any one of them report data initial method.
10. a kind of storage medium, which is characterized in that the storage medium is stored with computer program, the computer program packet Program instruction is included, described program instruction makes the processor execute such as any one of claim 1-5 institutes when being executed by a processor The report data initial method stated.
CN201810214183.5A 2018-03-15 2018-03-15 Report data initialization method and device, computer equipment and storage medium Active CN108415894B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201810214183.5A CN108415894B (en) 2018-03-15 2018-03-15 Report data initialization method and device, computer equipment and storage medium
PCT/CN2018/102610 WO2019174191A1 (en) 2018-03-15 2018-08-28 Report data initialization method and apparatus, and computer device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810214183.5A CN108415894B (en) 2018-03-15 2018-03-15 Report data initialization method and device, computer equipment and storage medium

Publications (2)

Publication Number Publication Date
CN108415894A true CN108415894A (en) 2018-08-17
CN108415894B CN108415894B (en) 2021-01-05

Family

ID=63131650

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810214183.5A Active CN108415894B (en) 2018-03-15 2018-03-15 Report data initialization method and device, computer equipment and storage medium

Country Status (2)

Country Link
CN (1) CN108415894B (en)
WO (1) WO2019174191A1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2019174191A1 (en) * 2018-03-15 2019-09-19 平安科技(深圳)有限公司 Report data initialization method and apparatus, and computer device and storage medium
CN112447300A (en) * 2020-11-27 2021-03-05 平安科技(深圳)有限公司 Medical query method and device based on graph neural network, computer equipment and storage medium

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111680478B (en) * 2020-06-17 2024-04-16 华自科技股份有限公司 Report generation method, device, equipment and storage medium based on configuration software

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100223297A1 (en) * 2007-03-30 2010-09-02 Alibaba Group Holding Limited Data Merging in Distributed Computing
CN104216952A (en) * 2014-08-20 2014-12-17 烽火通信科技股份有限公司 Universal report generation method and universal report generation system based on XML (extensive markup language) technology
CN107423387A (en) * 2017-07-19 2017-12-01 北京北信源软件股份有限公司 The method and apparatus of table is divided in a kind of point storehouse based on middleware

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101866350A (en) * 2010-05-11 2010-10-20 中兴通讯股份有限公司 Report generation method and device as well as WEB server
CN103678575B (en) * 2013-12-11 2016-03-02 四川九洲电器集团有限责任公司 By the method and system of the unified process of Middleware implementation several data database data
CN104572122B (en) * 2015-01-28 2018-04-27 中国工商银行股份有限公司 A kind of generating means and method of software application data
CN107168940B (en) * 2017-03-29 2020-06-16 长春市万易科技有限公司 Report generation system and method
CN108415894B (en) * 2018-03-15 2021-01-05 平安科技(深圳)有限公司 Report data initialization method and device, computer equipment and storage medium

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100223297A1 (en) * 2007-03-30 2010-09-02 Alibaba Group Holding Limited Data Merging in Distributed Computing
CN104216952A (en) * 2014-08-20 2014-12-17 烽火通信科技股份有限公司 Universal report generation method and universal report generation system based on XML (extensive markup language) technology
CN107423387A (en) * 2017-07-19 2017-12-01 北京北信源软件股份有限公司 The method and apparatus of table is divided in a kind of point storehouse based on middleware

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2019174191A1 (en) * 2018-03-15 2019-09-19 平安科技(深圳)有限公司 Report data initialization method and apparatus, and computer device and storage medium
CN112447300A (en) * 2020-11-27 2021-03-05 平安科技(深圳)有限公司 Medical query method and device based on graph neural network, computer equipment and storage medium
CN112447300B (en) * 2020-11-27 2024-02-09 平安科技(深圳)有限公司 Medical query method and device based on graph neural network, computer equipment and storage medium

Also Published As

Publication number Publication date
WO2019174191A1 (en) 2019-09-19
CN108415894B (en) 2021-01-05

Similar Documents

Publication Publication Date Title
CN108415894A (en) Report data initial method, device, computer equipment and storage medium
CN104081702B (en) Method for sending/receiving grouping in a communications system
CN110445860B (en) Message sending method, device, terminal equipment and storage medium
CN101316241B (en) TLV format processing method for communication data
CN109413154A (en) Conversion method of data format, device, computer equipment and storage medium
CN106464427A (en) Data processing method, and data sending end and receiving end
CN103534968B (en) The coding of a kind of ethernet physical layer, coding/decoding method and device
CN108388622A (en) Api interface dynamic creation method, device, computer equipment and storage medium
US11599708B2 (en) Encoding of data formatted in human readable text according to schema into binary
CN101807205B (en) Processing module, device, and method for processing of xml data
CN109240739A (en) A kind of method, apparatus and controlled terminal of rapid configuration BIOS option
CN109392100B (en) Method, device and equipment for determining size of transmission block
CN108717461A (en) Mass data structural method, device, computer equipment and storage medium
CN108762955A (en) Interface call method, device, computer equipment and storage medium
CN107683592A (en) Data processing method, device and system
CN1973282A (en) System and method for managing a change to a cluster configuration
CN107181794B (en) DICOM network transmission method based on DIMSE message sending and receiving
CN108446371A (en) Data return guiding method, device, computer equipment and storage medium
CN107707598A (en) The method and Internet of Things communication equipment of a kind of remote control Internet of Things communication equipment
CN102868557B (en) Method for realizing configuration synchronization between network manager and xPON (x-passive optical network) device
CN108881124A (en) Method, system, storage medium and the equipment of high performance communication are realized in intermodule
CN109413077A (en) A kind of receiving/transmission method, device and the electronic equipment of JSON message data
US9065789B2 (en) Remote communication method
CN108259500A (en) A kind of RPC means of communication, system and device
CN105139053B (en) Radio-frequency identification reader/writer interface protocol debugging apparatus and method

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