Method for carrying out OLAP (On-Line Analytical Processing) query on bank mass offline data
Patent Information
- Application Number
- CN202410842425.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-27
- Publication Date
- 2024-09-10
Smart Images

Figure CN118626524A
Abstract
Description
Technical Field
[0001] The present invention relates to the field of bank logs and business systems, and in particular to an OLAP query method for massive offline data of a bank. Background Art
[0002] Cellulose, as a macromolecular biomass material, is used in lithium-ion batteries, providing a promising prospect for the development of green, high-performance batteries. Lithiated cellulose nanocrystals (Li-CNFs) formed by lithiation of cellulose nanocrystals (CNFs) play a role in replenishing lithium in lithium-ion batteries, which is beneficial to improving the cycle life and energy density of lithium-ion batteries.
[0003] In the prior art, carboxymethyl cellulose is mainly subjected to a lithiation reaction to generate carboxymethyl cellulose lithium (CMC-Li), and an aqueous solution is mainly used for the reaction during the synthesis process. Carboxymethyl cellulose contains a small amount of crystal water, which greatly affects the performance of lithium-ion batteries.
[0004] There are various solutions for OLAP query and analysis of massive offline data. Some are based on in-memory computing principles, and some are based on pre-computation principles. However, there is a problem of slow response efficiency for massive detailed data queries and multi-dimensional aggregate data queries. Summary of the invention
[0005] In view of the above problems, the present invention is proposed to provide a method for performing OLAP query on massive offline data of a bank, which overcomes the above problems or at least partially solves the above problems.
[0006] According to one aspect of the present invention, a method for performing OLAP query on massive offline data of a bank is provided, the query method comprising:
[0007] Step S1: connecting to data source;
[0008] Step S2: perform custom dimension modeling on the data source table;
[0009] Step S3: Full snapshot processing;
[0010] Step S4: Customize the aggregation index for the dimensional model to form a multi-dimensional aggregation rule;
[0011] Step S5: According to the multi-dimensional aggregation rules, the data source is loaded into the dimensional model to form the data details and the pre-calculated results of various dimensional aggregations;
[0012] Step S6: query and visualize the pre-calculated results.
[0013] Optionally, the step S1: connecting to the data source specifically includes: connecting to the data source and storing the massive data table in shards.
[0014] Optionally, the step S2: performing custom dimension modeling on the data source table specifically includes:
[0015] Perform custom dimension modeling on the data source table, and leftjoin the fact table to the dimension table without using innerjoin or rightjoin, to ensure detailed data query on the fact form table;
[0016] For large dimension tables with billions of data volumes, the dimension tables are modeled separately as fact tables to ensure detailed data queries on large dimension tables with billions of data volumes.
[0017] Obtain the corresponding dimensional model and perform detailed data queries on massive fact tables and massive dimension tables at the same time.
[0018] Optionally, the step S3: full snapshot processing specifically includes:
[0019] Full snapshot processing: perform full snapshot processing on small dimension tables with a data volume of less than hundreds of thousands in the dimensional model, and perform detailed data query on the small dimension tables.
[0020] Optionally, the step S4: customizing the aggregation index for the dimensional model to form a multi-dimensional aggregation rule specifically includes:
[0021] Customize aggregation indexes for dimensional models, define high-base dimensions as required dimensions, define precise indexes for commonly used dimension combinations, define fallback indexes for uncommon dimension combinations, control the number of indexes, and form the final multi-dimensional aggregation rules.
[0022] Optionally, the step S5: loading the data source into the dimensional model according to the multi-dimensional aggregation rule to form the data details and the pre-calculation results of various dimensional aggregations specifically includes:
[0023] According to the multi-dimensional aggregation rules, the fact table and dimension table data are loaded into the dimensional model to form the pre-calculated results of data details and various dimensional aggregations, so that the detailed data of each table and the aggregation results of the dimensional model can be efficiently queried.
[0024] Optionally, the step S6: querying and visually displaying the pre-calculation result specifically includes:
[0025] The front-end page calls Apache Kylin's REST API to perform OLAP efficient query analysis on the result values and visualize them.
[0026] The present invention provides an OLAP query method for massive offline data of a bank, the query method comprising: step S1: docking data source; step S2: custom dimension modeling of data source table; step S3: full snapshot processing; step S4: custom aggregation index of dimension model to form multidimensional aggregation rules; step S5: according to multidimensional aggregation rules, data source is loaded into dimension model to form data details and pre-calculated results of various dimensional aggregations; step S6: query and visualize the pre-calculated results. OLAP query analysis is adopted to improve query efficiency.
[0027] The above description is only an overview of the technical solution of the present invention. In order to more clearly understand the technical means of the present invention, it can be implemented according to the contents of the specification. In order to make the above and other purposes, features and advantages of the present invention more obvious and easy to understand, the specific implementation methods of the present invention are listed below. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying any creative work.
[0029] Figure 1 The present invention provides a flowchart of a method for performing OLAP query on massive offline data of a bank. DETAILED DESCRIPTION
[0030] The exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although exemplary embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure may be implemented in various forms and should not be limited by the embodiments described herein. On the contrary, these embodiments are provided to enable a more thorough understanding of the present disclosure and to fully convey the scope of the present disclosure to those skilled in the art.
[0031] The terms "comprises" and "having" and any variations thereof in the description embodiments, claims and drawings of the present invention are intended to cover non-exclusive inclusions, for example, including a series of steps or units.
[0032] The technical solution of the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments.
[0033] The present invention is a method for performing efficient OLAP query on massive offline data of a bank, which solves the problem of performing efficient detailed query and multi-dimensional aggregation query on massive offline detailed data, so that bank data analysts can mine valuable data more efficiently.
[0034] The overall solution is based on the bank's massive offline detailed data set, using the Apache Kylin tool for custom dimensional modeling and processing, and loading the massive offline detailed data set into the corresponding model through custom details and aggregation indexes, thereby obtaining details and aggregation results under various dimensional combinations. Finally, the front-end page calls Apache Kylin's REST API (presentation layer state transfer application programming interface) to perform OLAP efficient query analysis and visualize the result values.
[0035] like Figure 1 As shown, the technical implementation scheme of the present invention is summarized as follows:
[0036] Based on the bank's massive offline detailed data set, Apache Kylin tool is used for custom dimension modeling and processing, and the massive offline detailed data set is loaded into the corresponding model through custom details and aggregation indexes, so as to obtain the details and aggregation results under various dimensional combinations. Finally, the front-end page calls Apache Kylin's RESTAPI (presentation layer state transfer application programming interface) to perform OLAP efficient query analysis and visualize the result value.
[0037] Apache Kylin is a distributed multidimensional data analysis (OLAP) engine. Apache Kylin is a MOLAP engine in OLAP. It calculates the combination of multiple dimensions in advance and forms a multidimensional data set. It is mainly used for multidimensional query analysis of data.
[0038] In the method of efficient OLAP query on massive offline data of banks, in the process of processing massive offline detailed data sets of banks, the Apache Kylin tool is used to customize dimension modeling and process data, and then customize indexes to calculate the details and aggregation results under various dimensional combinations. Finally, the front-end page performs OLAP query on the result values and displays them.
[0039] A method for performing OLAP query on massive offline data of a bank, comprising:
[0040] Step 1: Connect to the data source;
[0041] Step 2: Customize dimension modeling for the data source table;
[0042] Step 3: Full snapshot processing;
[0043] Step 4: Customize the aggregation index for the dimensional model to form multi-dimensional aggregation rules;
[0044] Step 5: According to the multi-dimensional aggregation rules, the data source is loaded into the dimensional model to form the data details and pre-calculated results of various dimensional aggregations;
[0045] Step 6: The front-end page calls Apache Kylin’s REST API to perform OLAP efficient query analysis on the result values and visualize them.
[0046] A method for performing OLAP query on massive offline data of a bank, comprising:
[0047] Step 1: Connect to the data source and store the massive data table in shards to make the massive data loading process more efficient;
[0048] Step 2: Customize dimension modeling for the data source table, and leftjoin the fact table to the dimension table without using innerjoin or rightjoin, to ensure detailed data query for the fact table. In addition, for large dimension tables with billions of data, it is necessary to model the dimension table as a separate fact table to ensure detailed data query for large dimension tables with billions of data. Finally, the corresponding dimension model is obtained, and detailed data query is performed on massive fact tables and massive dimension tables at the same time.
[0049] Step 3: Full snapshot processing: small dimension tables with a data volume of less than hundreds of thousands in the dimensional model are fully snapshotted so that detailed data can be queried on the small dimension tables.
[0050] Step 4: Customize the aggregation index for the dimensional model, define the high-base dimension as a required dimension, define the precise index for the commonly used dimension combination, and define the backup index for the uncommon dimension combination, control the number of indexes, and form the final multi-dimensional aggregation rules;
[0051] Step 5: According to the multidimensional aggregation rules, the fact table and dimension table data are loaded into the dimensional model to form the pre-calculated results of data details and various dimensional aggregations, so that the detailed data of each table and the aggregation results of the dimensional model can be efficiently queried;
[0052] Step 6: The front-end page calls Apache Kylin’s REST API to perform OLAP efficient query analysis on the result values and visualize them.
[0053] Beneficial effects: OLAP query analysis of massive offline data can achieve sub-second response, and query efficiency is higher;
[0054] The source tables of massive offline detailed data sets are stored in shards, making data processing more efficient.
[0055] Achieve efficient query of the details of each table;
[0056] Dimension tables with billions of data volumes are modeled separately as fact tables to ensure efficient query of their details and higher loading efficiency.
[0057] The above specific implementation methods further illustrate the objectives, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above are only specific implementation methods of the present invention and are not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.
Claims
1. A method for performing OLAP query on massive offline data of a bank, characterized in that: The query method comprises: Step S1: connecting to data source; Step S2: perform custom dimension modeling on the data source table; Step S3: Full snapshot processing; Step S4: Customize the aggregation index for the dimensional model to form a multi-dimensional aggregation rule; Step S5: According to the multi-dimensional aggregation rules, the data source is loaded into the dimensional model to form the data details and the pre-calculated results of various dimensional aggregations; Step S6: query and visualize the pre-calculated results.
2. The method for performing OLAP query on massive offline bank data according to claim 1, characterized in that: The step S1: connecting to the data source specifically includes: connecting to the data source and storing the massive data table in segments.
3. The method for performing OLAP query on massive offline bank data according to claim 1, characterized in that: The step S2: performing custom dimension modeling on the data source table specifically includes: Perform custom dimension modeling on the data source table, and leftjoin the fact table to the dimension table without using inner join or right join to ensure detailed data query on the fact table. For large dimension tables with billions of data volumes, the dimension tables are modeled separately as fact tables to ensure detailed data queries on large dimension tables with billions of data volumes. Obtain the corresponding dimensional model and perform detailed data queries on massive fact tables and massive dimension tables at the same time.
4. The method for performing OLAP query on massive offline bank data according to claim 1, characterized in that: The step S3: full snapshot processing specifically includes: Full snapshot processing: perform full snapshot processing on small dimension tables with a data volume of less than hundreds of thousands in the dimensional model, and perform detailed data query on the small dimension tables.
5. The method for performing OLAP query on massive offline bank data according to claim 1, characterized in that: The step S4: customizing the aggregation index of the dimensional model to form a multi-dimensional aggregation rule specifically includes: Customize aggregation indexes for dimensional models, define high-base dimensions as required dimensions, define precise indexes for commonly used dimension combinations, define fallback indexes for uncommon dimension combinations, control the number of indexes, and form the final multi-dimensional aggregation rules.
6. The method for performing OLAP query on massive offline bank data according to claim 1, characterized in that: The step S5: according to the multi-dimensional aggregation rules, the data source is loaded into the dimensional model to form the data details and the pre-calculation results of various dimensional aggregations, which specifically include: According to the multi-dimensional aggregation rules, the fact table and dimension table data are loaded into the dimensional model to form the pre-calculated results of data details and various dimensional aggregations, so that the detailed data of each table and the aggregation results of the dimensional model can be efficiently queried.
7. The method for performing OLAP query on massive offline bank data according to claim 1, characterized in that: The step S6: querying and visually displaying the pre-calculation results specifically includes: The front-end page calls Apache Kylin's REST API to perform OLAP efficient query analysis on the result values and visualize them.
