Database-based data display method, system, device, and medium
By using a database-based visualization data display method, users can select and associate database tables through simple operations, solving the inefficiency problem caused by complex query statements in existing technologies, and achieving efficient and low-cost data query and analysis.
Patent Information
- Application Number
- CN202310459974.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-04-20
- Publication Date
- 2026-01-06
- Estimated Expiration
- 2043-04-20
AI Technical Summary
In existing technologies, comprehensive database data analysis requires operators to have strong professional knowledge and write complex query statements, resulting in low data query efficiency and high cost, especially when switching between multiple types of databases, which is even more complex and inefficient.
By using a database-based data display method, database information is displayed through a visual interface. Users can select and associate database tables through simple human-computer operations, and the target data is finally displayed on the visual interface by combining filtering rules and association results.
It simplifies database operations, improves data query efficiency, reduces query costs, and enables non-professionals to perform data analysis, making it suitable for rapid integration and statistical analysis in the era of big data.
Smart Images

Figure CN116561123B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of database technology, and in particular to a database-based data display method, system, device, and medium. Background Technology
[0002] As enterprise informatization deepens and information systems grow increasingly large, the amount of data increases exponentially, driving the advancement of information technology and giving rise to various databases. Several subsystems select different types of databases with their own advantages according to their own data storage needs in order to meet the functional and performance requirements of the system. This will inevitably lead to the increasing complexity of system data.
[0003] In related technologies, when performing comprehensive data analysis on data in a database, operators often need to have strong professional knowledge, be familiar with various database syntaxes, write a large number of complex query statements, and perform various transformations on intermediate processing results, which reduces the efficiency of data query and increases the cost of data query. Summary of the Invention
[0004] The main objective of this application is to propose a database-based data display method, system, device, and medium that can improve the efficiency of data query and reduce the cost of data query.
[0005] To achieve the above objectives, a first aspect of this application proposes a database-based data display method, the method comprising: in response to a database addition operation, displaying initial basic information of the database in a preset data source interface; in response to a first selection operation for the database, displaying an initial database table under target basic information in the data source interface, wherein the target basic information is selected from the initial basic information; in response to a second selection operation for the initial database table, displaying a target database table in a preset data editing interface, wherein the target database table is selected from the initial database table; if there are multiple target database tables, in response to a join operation for the target database tables, displaying the join result of the target database tables in a preset data preview interface; and in response to a confirmation operation for the result display, displaying target data in a preset data visualization interface, wherein the target data is generated by the target database tables after the join operation is completed in conjunction with the join result.
[0006] In some embodiments, displaying target data on a preset data visualization interface in response to a confirmation operation for result display includes: obtaining filtering rules for filtering information in the target database table; filtering the information in the target database table according to the filtering rules, and displaying the filtered information in the target database table on the data preview interface; and displaying target data on a preset data visualization interface in response to a confirmation operation for result display, wherein the target data is generated after the filtered target database table has been associated with the associated results.
[0007] In some embodiments, obtaining the filtering rules for filtering information in the target database table includes: displaying multiple initial fields and corresponding initial filtering conditions for filtering operations on a preset data filtering interface; in response to a third selection operation for the filtering rules, displaying the target field and target filtering conditions after value taking on the data filtering interface, wherein the target field is selected from the initial fields and obtained by taking values, and the target filtering conditions are selected from the initial filtering conditions; and displaying the filtering rules obtained based on the target field and the target filtering conditions on the data filtering interface.
[0008] In some embodiments, if there is only one target database table, the method further includes: querying the target database table using a preset query statement, displaying detailed information corresponding to the target database table in a preset data preview interface; and displaying the detailed information in a preset data visualization interface in response to a confirmation operation of the result display.
[0009] In some embodiments, displaying the association result of the target database table on a preset data preview interface in response to the association operation on the target database table includes: determining the association relationship between each of the target database tables in response to the association operation on the target database table, wherein the association relationship includes inner join, left join, right join or full join; and displaying the association result obtained by performing the association operation on each of the target database tables according to the association relationship on the preset data preview interface.
[0010] In some embodiments, displaying the association results of each target database table after association operations based on the association relationship on a preset data preview interface includes: if the target database tables all come from the same database, querying the target database tables in the same database using a preset query statement, and displaying the association results of each target database table after association operations based on the association relationship on the preset data preview interface; if the target database tables come from different databases, creating soft connections between different databases uniformly through a preset connection creation function, and returning aliases for pointing to different database connections, querying the target database tables in different databases according to the aliases and a preset standard query statement, and displaying the association results of each target database table after association operations based on the association relationship on the preset data preview interface.
[0011] In some embodiments, the step of displaying target data on a preset data visualization interface in response to a confirmation operation of the result display includes: performing a correlation operation on the target database table in response to the confirmation operation of the result display to obtain the target data; converting the target data into a chart and displaying the chart on the preset data visualization interface, wherein the chart includes a line chart, a bar chart, or a pie chart.
[0012] In some embodiments, converting the target data into a chart includes: analyzing the field type of each target field in the target data, determining each target field as an initial dimension field or an initial metric field based on the field type, wherein a dimension represents the angle of analysis, and a metric represents a quantifiable indicator; obtaining preset display rules, determining the target dimension field or target metric field for visualization from the initial dimension field or the initial metric field based on the display rules; determining the chart type based on the target dimension field and the target metric field, and displaying the chart of the target data under the chart type on a preset data visualization interface.
[0013] In some embodiments, under the display rules, determining the target dimension field or target metric field for visualization from the initial dimension field or the initial metric field includes: performing deduplication calculation on each initial dimension field or the initial metric field to obtain the number of different values under the corresponding field; obtaining the total number of records of the target data, and performing a percentage calculation based on the number of different values under the corresponding field and the total number of records to obtain a corresponding percentage value; determining the initial dimension field with the largest percentage value as the default target dimension field, or determining the initial metric field with the smallest percentage value as the default target metric field.
[0014] In some embodiments, the method further includes: displaying a data visualization window; the data visualization window is divided into a first display area, a second display area, and a third display area according to their functions, wherein the first display area is used to display the data source interface, the second display area is used to display the data editing interface and the data filtering interface, and the third display area is used to display the data preview interface and the data visualization interface.
[0015] In some embodiments, converting the target data into a chart includes: obtaining user identification information; matching a corresponding recommendation probability based on the identification information; generating a first chart based on the recommendation probability and the target data; converting the target data into a second chart; if the first chart and the second chart are of different types, displaying a chart selection interface; and displaying a target chart in a preset data visualization interface in response to the chart selection operation, wherein the target chart is one of the first chart or the second chart.
[0016] To achieve the above objectives, a second aspect of this application proposes a database-based data display system, comprising: a data source module, configured to display initial basic information of the database in a preset data source interface in response to a database add operation; the data source module is further configured to display an initial database table under target basic information in the data source interface in response to a first selection operation for the database, wherein the target basic information is selected from the initial basic information; a data editing module, configured to display a target database table in a preset data editing interface in response to a second selection operation for the initial database table, wherein the target database table is selected from the initial database table; a data preview module, configured to display the association result of the target database tables in a preset data preview interface in response to an association operation for the target database tables if there are multiple target database tables; and a data visualization module, configured to display target data in a preset data visualization interface in response to a confirmation operation for the result display, wherein the target data is generated by the target database tables after completing the association operation in conjunction with the association result.
[0017] To achieve the above objectives, a third aspect of this application provides an electronic device, which includes a memory and a processor. The memory stores a computer program, and the processor executes the computer program to implement the database-based data display method described in the first aspect embodiment.
[0018] To achieve the above objectives, a fourth aspect of the present application provides a storage medium, which is a computer-readable storage medium storing a computer program that, when executed by a processor, implements the database-based data display method described in the first aspect of the present application.
[0019] The database-based data display method, system, device, and medium proposed in this application can be applied to database-based data display systems. By executing this method, the initial basic information of the database is first displayed on the data source interface in a visual manner. After the user selects the database to be queried, the selected target basic information is confirmed, and the initial database table is displayed under the target basic information. After the user completes the selection of the database table, the selected target database table is displayed on the data editing interface. If there are multiple target database tables, they can be linked, and the linking results are displayed on a preset data preview interface. After the user confirms the preview results are correct, the target data generated after the linking operation is completed by combining the linking results is finally displayed on the data visualization interface. This application simplifies data querying from the database. By visually displaying relevant information and completing form selection and linking through simple human-computer operations, the required data is finally displayed, thereby improving the efficiency and reducing the cost of data querying. Attached Figure Description
[0020] Figure 1 These are schematic diagrams illustrating the display effects of various interfaces provided in the embodiments of this application;
[0021] Figure 2 This is a schematic flowchart of a database-based data display method provided in an embodiment of this application;
[0022] Figure 3 yes Figure 2 Step S105 also includes a schematic diagram of the data filtering process;
[0023] Figure 4 yes Figure 3 A flowchart illustrating step S201 in the process;
[0024] Figure 5 This is a flowchart illustrating the division of the display interface provided in an embodiment of this application;
[0025] Figure 6 This application provides a flowchart illustrating a single-database, single-table query process in its embodiments.
[0026] Figure 7 yes Figure 2 A flowchart illustrating step S104 in the process;
[0027] Figure 8 yes Figure 7 A flowchart illustrating step S602 in the process;
[0028] Figure 9 yes Figure 2 Step S105 also includes a flowchart for displaying a diagram;
[0029] Figure 10 yes Figure 9 A flowchart illustrating the process of determining dimensions or metrics in step S802 of the process;
[0030] Figure 11 yes Figure 10 A flowchart illustrating step S902 in the process;
[0031] Figure 12 yes Figure 9 A flowchart illustrating the process of determining the displayed chart based on user identification information in step S802.
[0032] Figure 13 This is a schematic diagram of the functional modules of the database-based data display system provided in the embodiments of this application;
[0033] Figure 14 This is a schematic diagram of the hardware structure of the electronic device provided in the embodiments of this application. Detailed Implementation
[0034] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0035] It should be noted that although functional modules are divided in the device schematic diagram and a logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than the module division in the device or the order in the flowchart. The terms "first," "second," etc., in the specification, claims, and the aforementioned drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence.
[0036] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein is for the purpose of describing embodiments of this application only and is not intended to limit this application.
[0037] As enterprise informatization deepens and information systems grow larger, data volume increases exponentially, driving the advancement of information technology and giving rise to various databases. Several subsystems select different types of databases with their own advantages according to their own data storage needs to meet the functional and performance requirements of the system. This will inevitably lead to increasingly complex system data.
[0038] In related technologies, when performing comprehensive data analysis on data in a database, operators often need to have strong professional knowledge, be familiar with various database syntaxes, write a large number of complex query statements, and perform various transformations on intermediate processing results, which reduces the efficiency of data query and increases the cost of data query.
[0039] Furthermore, existing tools or systems are vulnerable to comprehensive data analysis involving multiple types of databases. This not only requires operators to frequently switch between multiple different database management systems, but also increases query costs due to the different query statements for different types of databases. This makes data querying work complex and inefficient, ultimately affecting the efficiency of data analysis.
[0040] Based on this, embodiments of this application provide a database-based data display method, system, device, and medium, which simplifies data querying in the database, visualizes relevant information, and allows users to select and associate forms through simple human-computer operations, ultimately displaying the required data. This improves the efficiency of data querying, reduces the cost of data querying, and ultimately enhances the efficiency of data analysis.
[0041] The database-based data display method, system, device, and medium provided in this application are specifically described through the following embodiments. First, the database-based data display system in this application is described.
[0042] The database-based data display system (hereinafter referred to as the system) is equipped with a terminal and a back-end server. The terminal is equipped with a display screen, which acts as the front end. The terminal is connected to the back-end server. The server can store data from different types of databases, such as MySQL, SQL Server, PostgreSQL, Oracle, etc., without any specific restrictions.
[0043] like Figure 1As shown, the display screen can show a data visualization window, which sequentially displays the data source interface, data editing interface, data preview interface, data filtering interface, and data visualization interface. When displaying data, the initial basic information of the database is first displayed on the data source interface. After the user selects the database to query, the selected target basic information is confirmed, and the initial database tables are displayed below the target basic information. After the user completes the selection of database tables, the selected target database tables are displayed in the data editing interface. If there are multiple target database tables, join operations can be performed between them, and the join results are displayed in the preset data preview interface. In addition, data filtering configurations can be implemented in the data filtering interface to filter out redundant data. After the user confirms that the preview results are correct, the final target data generated after the join operation is completed by combining the join results is displayed in the data visualization interface.
[0044] The data source interface is located on the left side of the data visualization window, the data editing interface is located on the upper right side of the data source interface, the data preview interface is located on the right side of the data editing interface, the data filtering interface is located on the lower right side of the data source interface and below the data editing interface, and the data visualization interface is located on the right side of the data filtering interface and below the data preview interface.
[0045] It is understandable that a display screen can divide the displayed area into multiple regions, including a data source interface, a data editing interface, a data preview interface, a data filtering interface, and a data visualization interface. It is also understandable that these regions can be displayed independently or in a hierarchical manner, with different interfaces overlapping when displayed in a layered fashion.
[0046] For example, the different interfaces mentioned above can be enlarged based on user actions or based on the system's default configuration.
[0047] For example, the database-based data display system in this application embodiment can serve as a data visualization tool based on heterogeneous databases. It facilitates connections between heterogeneous databases, simplifying cross-database access. Users can perform complex operations through simple drag-and-drop functionality. It also provides one-click visualization, allowing users to quickly grasp data patterns and trends through intuitive charts, making statistical analysis simple and efficient. On one hand, it lowers the barrier to database operation; even business personnel without database expertise can learn to operate databases and tables through simple tutorials. On the other hand, it simplifies data analysis, reducing costs. By encapsulating complex processes, business personnel can focus on the analysis of the data itself without worrying about visualization. Furthermore, it is more suitable for the big data era, where data is fundamental. Rapid data integration and statistical analysis help enterprises understand the situation and make business decisions.
[0048] Based on this, the database-based data display method in the embodiments of this application can be described through the following examples.
[0049] The embodiments of this application can acquire and process relevant data based on artificial intelligence technology. Artificial intelligence (AI) refers to the theories, methods, technologies, and application systems that use digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use that knowledge to obtain optimal results.
[0050] Foundational technologies for artificial intelligence generally include sensors, dedicated AI chips, cloud computing, distributed storage, big data processing, operating / interactive systems, and mechatronics. AI software technologies mainly encompass computer vision, robotics, biometrics, speech processing, natural language processing, and machine learning / deep learning.
[0051] The database-based data display method provided in this application relates to the field of artificial intelligence technology. This database-based data display method can be applied to a terminal, a server, or software running on either a terminal or a server. In some embodiments, the terminal can be a smartphone, tablet, laptop, desktop computer, etc.; the server can be configured as an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms; the software can be an application implementing the database-based data display method, but is not limited to the above forms.
[0052] This application can be used in a wide variety of general-purpose or special-purpose computer system environments or configurations. Examples include: personal computers, server computers, handheld or portable devices, tablet devices, multiprocessor systems, microprocessor-based systems, set-top boxes, programmable consumer electronics, network PCs, minicomputers, mainframe computers, and distributed computing environments including any of the above systems or devices. This application can be described in the general context of computer-executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform specific tasks or implement specific abstract data types. This application can also be practiced in distributed computing environments where tasks are performed by remote processing devices connected via a communication network. In distributed computing environments, program modules can reside in local and remote computer storage media, including storage devices.
[0053] It should be noted that in all specific embodiments of this application, when processing data related to user identity or characteristics, such as user information, user behavior data, user historical data, and user location information, user permission or consent is obtained first. For example, when obtaining user-stored data and user cached data access requests, user permission or consent is obtained first; when obtaining data from the database, user permission or consent is obtained first in this application embodiment. Moreover, the collection, use, and processing of this data comply with the relevant laws, regulations, and standards of the relevant countries and regions. Furthermore, when this application embodiment needs to obtain sensitive personal information of users, separate permission or consent from the user is obtained through pop-ups or redirection to a confirmation page. Only after obtaining the user's separate permission or consent is the necessary user-related data for the normal operation of this application embodiment obtained.
[0054] Figure 2 This is an optional flowchart of a database-based data display method provided in the embodiments of this application. Figure 2 The method may include, but is not limited to, steps S101 to S105.
[0055] Step S101: In response to the database addition operation, the initial basic information of the database is displayed in the preset data source interface.
[0056] Step S102, in response to the first selection operation for the database, the initial database table under the target basic information is displayed on the data source interface, wherein the target basic information is selected from the initial basic information;
[0057] Step S103: In response to the second selection operation for the initial database table, the target database table is displayed in the preset data editing interface, wherein the target database table is selected from the initial database table;
[0058] Step S104: If there are multiple target database tables, in response to the join operation on the target database tables, the join result of the target database tables is displayed in the preset data preview interface.
[0059] Step S105: In response to the confirmation operation of the result display, the target data is displayed on the preset data visualization interface. The target data is generated by the target database table after the association operation is completed by combining the association results.
[0060] For example, the database-based data display method (or simply method) in this application embodiment is applied to the database-based data display system described in the above embodiments. The structure of the system has been described in the above embodiments and will not be repeated here.
[0061] The data source interface is specifically designed to display basic information about the database. Different databases can be referred to as data sources. Both the initial basic information and the target basic information are fundamental database information, which may include the database's name, type, source, and size. This basic information provides an understanding of the database's basic characteristics.
[0062] Adding a database can be a user input operation on the display screen. For example, the screen could show a database configuration input interface or a database selection interface, where the user can input database addition commands and select the database to be displayed on the data source interface. For instance, adding a database can be an input operation for database information or a selection operation for information displayed on the interface; no specific limitations are imposed here.
[0063] The initial basic information is the basic information of the corresponding database. Different databases have different initial basic information. That is, the initial basic information represents the basic information of each database before the selection is made.
[0064] When executing the method, the system can first display the data source interface on the display screen, and the user can perform database addition operations on the data source interface. In response to the operation, the system performs a database query in the backend, returns the initial basic information of the database to be added, and displays it on the data source interface.
[0065] The target basic information is one or more of the initial basic information selected after the initial basic information is selected. The word "target" represents the selection.
[0066] The initial database table is a table that displays form information from the corresponding database after the user selects one or more target basic information. For example, the initial database table displayed on the data source interface contains basic information such as the table name, table source, and table size. It's understandable that a database may contain multiple tables, therefore each database may have multiple initial database tables.
[0067] The first selection operation is the user's selection on the data source interface. This operation allows them to select the database to be visualized. Essentially, the user can complete the first selection by clicking on an item related to the initial basic information of a database, thus identifying that database as the target database. It's also understood that if multiple first selection operations are performed, multiple target databases will be selected, resulting in multiple sets of target basic information, and these target databases can be of different types.
[0068] For example, users can add one or more associated databases, select the database type, and the connection parameter list will automatically switch according to the type. Users fill in the parameters required for a successful database connection, connect to the specified database server, and complete the addition of associated databases in sequence. After the addition is completed, multiple databases are displayed in a list on the data source interface on the left side of the window. Double-clicking a database displays all the tables under that database.
[0069] The data editing interface is a dedicated interface for editing data. For example, the display screen can show the data editing interface, through which users can perform configuration operations for linking different tables. The interface also displays the selected target database table, allowing users to visualize and clearly identify the currently selected table. No specific limitations are imposed here.
[0070] The second selection operation is a selection performed by the user on the data source interface, or between the data source interface and the data editing interface. Through this second selection operation, the target database table to be visualized can be selected. Understandably, users can complete the second selection operation by clicking, such as clicking on the initial database table under a specific database to confirm that the initial database table is the target database table. Alternatively, the second selection operation can also be a drag-and-drop operation; users can click on an initial database table in the data source area and drag it to the data editing interface.
[0071] The target database table is a database table selected after choosing from the initial database tables; the term "target" indicates that it has been selected. For example, the target database table displayed in the data editing interface includes basic information such as the table name, table source, and table size. It is understandable that if the user makes multiple second selections, there will be multiple selected target database tables, which can come from the same database or different databases.
[0072] The data preview interface is specifically designed for previewing data. For example, a display screen can show the data preview interface, allowing users to preview detailed information about database tables or the join relationships between multiple database tables. This ensures that the data to be displayed meets user requirements before the final data is shown.
[0073] Association operations can be either inputting or selecting association information. Association, also known as connection, refers to the relationship between database tables. These operations configure associations between selected target database tables. For example, if the association operation is an input operation, the user enters the association information between the target database tables, and the system performs the association operation based on the user's input. If the association operation is a selection operation, the screen displays options for the connection relationships between the target database tables; the user clicks "OK" or selects an option to obtain the association relationship.
[0074] It should be noted that, for multi-table scenarios, this embodiment of the application defaults to using fields with the same name in each table to determine the relationship, and defaults to determining an inner join relationship based on fields with the same name in the tables. Therefore, the join operation can also be a join confirmation operation, where users can click "Confirm" to select the automatically generated join relationship. In addition, after the system defaults to selecting the join relationship, users can manually switch the join fields and join methods to determine other join relationships, without specific restrictions here.
[0075] The association result can be a description of the relationship between database tables. For example, if table A and table B are target database tables, the association result can be "table A and table B have an inner join relationship". In addition, the association result can also be detailed information obtained by combining the target database tables after the association relationship, without specific restrictions.
[0076] A data visualization interface is a dedicated interface for displaying results. For example, a display screen can show a data visualization interface, and a data preview interface can show detailed information between target database tables, completing the display of query results. Users can understand the information they need to query through the data visualization interface, which helps them to intuitively observe information and facilitates subsequent data analysis.
[0077] The confirmation operation can be done by clicking the confirmation button. The screen displays an option to confirm or not. After previewing the selected target database table and the corresponding related results in the data preview interface, if the user believes that the information meets the query requirements, they can click the confirmation option in the interface to complete the confirmation operation.
[0078] Target data is the data generated after the target database table completes the join operation by combining the join results. It can be understood that target data can be detailed information about the target database table, including the content details of each table, the relationship between multiple tables, etc.
[0079] Understandably, the data preview interface can also display the target data generated after combining the results of the association with the target database table. Understandably, the target data displayed in the data preview interface is different from the target data displayed in the database visualization interface. The data preview interface can display a rough result, that is, the result before the data has been formatted or beautified, or it can be an overview of the details in the table. On the other hand, the target data displayed in the data visualization interface can be the final result presented to the client, which can be the result after the data has been formatted or beautified, making it more convenient for users to view.
[0080] In response to the confirmation operation of the result display, the target data is displayed in the preset data visualization interface. The target data is generated by the target database table after the association operation is completed in combination with the association results.
[0081] This application simplifies data querying in databases. When dealing with multiple databases and tables, there's no need to understand the query languages of different databases. Relevant information is displayed visually, and users complete form selection and association through simple human-computer interaction, ultimately displaying the required data. This significantly reduces the operational cost for users. Previously, different types of databases required programming languages to complete table associations and configurations, with varying configuration requirements between tables, further increasing the cost of query analysis. This application simplifies the display of forms from heterogeneous databases through visualization. Only simple human-computer interaction is required on the front end, while form querying and association configuration are completed on the back end. Users do not need to concern themselves with the backend processing logic, greatly improving system usability. Therefore, this application significantly improves data query efficiency and reduces data query costs.
[0082] Please see Figure 3 In some embodiments, step S105 may include steps S201 to S203:
[0083] Step S201: Obtain the filtering rules used to filter information in the target database table;
[0084] Step S202: Filter the information in the target database table according to the filtering rules, and display the filtered information in the target database table on the data preview interface;
[0085] Step S203: In response to the confirmation operation of the result display, the target data is displayed on the preset data visualization interface. The target data is generated after the filtered target database table completes the association operation by combining the association results.
[0086] Understandably, databases contain a large amount of information, including a lot of redundant data that does not meet the criteria. This data is not conducive to user viewing or has no analytical value, resulting in insufficient data conciseness. Therefore, it is necessary to filter and select this data.
[0087] Filtering rules are pre-set rules or rules derived from user configuration settings, and can be used to filter information in target database tables. If the filtering rules are pre-set, the system can use these pre-configured rules to filter the data after obtaining the target database tables or completing join operations between them; alternatively, users can set filtering conditions for specific target database tables to achieve data filtering.
[0088] In this embodiment of the application, after filtering the information in the target database table according to the filtering rules, the filtered information in the target database table is displayed on the data preview interface. Users can preview whether the information currently displayed in the target database table meets the filtering requirements, that is, whether there is any redundant or unanalyzable content. If the content is correct, users can confirm the result on the interface. The system then displays the filtered result on the data visualization interface.
[0089] Please see Figure 4 In some embodiments, step S201 may include steps S301 to S303:
[0090] Step S301: Display multiple initial fields and corresponding initial filtering conditions for filtering operations on the preset data filtering interface.
[0091] In step S302, in response to the third selection operation for the filtering rule, the target field and target filtering conditions after value taking are displayed on the data filtering interface, wherein the target field is selected from the initial field and obtained after value taking, and the target filtering conditions are selected from the initial filtering conditions.
[0092] Step S303: Display the filtering rules obtained based on the target field and target filtering conditions on the data filtering interface.
[0093] For example, in this application embodiment, fields and filtering conditions can be set to configure filtering rules, and this process can be performed on the data filtering interface.
[0094] The data filtering interface is specifically designed for setting filtering rules. For example, the display screen can show the data filtering interface, through which input fields for filtering rules can be shown, allowing users to enter specific information to complete the filtering rule settings. Alternatively, the data filtering interface can also display filtering rules for users to choose from; no specific restrictions are imposed here.
[0095] For example, the data filtering interface can display multiple initial fields and corresponding initial filter conditions for performing filtering operations. The initial fields are fields that the user can select, and the initial filter conditions are filter conditions that the user can select.
[0096] The third selection operation can be a selection made by the user on the data filtering interface. Through this operation, the user can select the desired field or filter condition, and also choose the range of values for the field. Understandably, the user can complete the third selection operation by clicking, such as clicking to confirm the target field and target filter condition in the initial field and initial filter conditions.
[0097] For example, in this embodiment of the application, different fields are selected as filtering conditions according to the data statistical analysis requirements, and the field is dragged to the data filtering interface. As needed, the field is filtered out by taking values or setting conditions, thus obtaining the target field and the target filtering conditions. Corresponding filtering rules can be generated accordingly to filter the target field under the target filtering conditions, and the filtering rules obtained based on the target field and the target filtering conditions are displayed on the data filtering interface.
[0098] Specifically, in this embodiment, user-inputted information can be dynamically received and applied to the aforementioned associated result set, filtering out redundant data that does not meet the conditions, making the data more concise and better suited to user expectations. Furthermore, users can add or remove fields or filtering conditions. The backend processes the result set according to the changes in instructions and returns the results to the frontend in real time for dynamic display in the data preview interface. The filtered data becomes the final analysis dataset.
[0099] Please see Figure 5 In some embodiments, the database-based data display method may further include steps S401 to S402:
[0100] Step S401: Display the data visualization window;
[0101] Step S402: The data visualization window is divided into a first display area, a second display area, and a third display area according to their functions. The first display area is used to display the data source interface, the second display area is used to display the data editing interface and the data filtering interface, and the third display area is used to display the data preview interface and the data visualization interface.
[0102] The data source interface is located on the left side of the data visualization window, the data editing interface is located on the upper right side of the data source interface, the data preview interface is located on the right side of the data editing interface, the data filtering interface is located on the lower right side of the data source interface and below the data editing interface, and the data visualization interface is located on the right side of the data filtering interface and below the data preview interface.
[0103] For example, in this embodiment, the positions of each visualization interface are determined in the data visualization window. The data source interface is located on the left side of the data visualization window, which conforms to the usage habit of "from left to right" so that the initial data sources are displayed first. After completing the selection of the database table, the user can "drag" the target database table to the adjacent data editing interface for display. Setting the data editing interface on the upper right side of the data source interface facilitates data "drag and drop". Subsequently, after completing the association operation in the data editing interface, the data can be previewed in the data preview interface on the right side of the data editing interface. In the data editing interface, the data filtering interface can be displayed, and the data configuration work can be completed on this vertical interface. The final data visualization interface, as the display interface of the final result, can be displayed in the lower right corner of the entire window.
[0104] like Figure 1 As shown, it can be understood that this embodiment of the application will display a data source interface, a data editing interface, a data preview interface, a data filtering interface, and a data visualization interface. According to the displayed functions, the data visualization window is divided into three parts, from left to right: a first display area, a second display area, and a third display area. The first display area is the source data display area, used to display the data source interface; the second display area is the configuration area, used to display the data editing interface and the data filtering interface; and the third display area is the example and result display area, used to preview the results and display the final results.
[0105] In this embodiment, the data visualization window is divided into different display contents according to function, which conforms to the conventional "left-to-right" usage approach and satisfies the display order of functions, so as to view the visualized data query process in sequence, thereby improving the efficiency of data query and ultimately improving the efficiency of data analysis. While meeting the requirements of this embodiment, the first display area, second display area, and third display area can also be in a top-to-bottom or right-to-left position relationship; this embodiment only limits the arrangement to left-to-right.
[0106] Please see Figure 6 In some embodiments, if there is only one target database table, the database-based data display method may further include steps S501 to S502:
[0107] Step S501: Use a preset query statement to query the target database table and display the detailed information of the target database table in the preset data preview interface;
[0108] In step S502, in response to the confirmation operation of the result display, detailed information is displayed on the preset data visualization interface.
[0109] For example, based on the database and server where the user-selected table resides, table associations are categorized into three types: single-database single-table, single-database multi-table, and multi-database multi-table. The backend processing logic differs for each of these three scenarios, and the implementation methods vary. In this embodiment, a method with low development costs and high processing efficiency can be selected based on the actual situation. After the backend code processes the data connection, it returns the associated result set to the frontend for display in the data preview interface. If there is only one target database table, the table association type is single-database single-table.
[0110] If there is only one target database table, you can directly use a query statement to query the specified table in the specified database and retrieve the data without table join operations. Specifically, you can use a preset query statement to query the target database table, display detailed information for the single table in a preset data preview interface, and then, after the user confirms that there are no errors, respond to the confirmation operation displayed above, and display detailed information in a preset data visualization interface.
[0111] Please see Figure 7 In some embodiments, step S104 may include steps S601 to S602:
[0112] Step S601: In response to the join operation on the target database table, determine the join relationship between the target database tables, wherein the join relationship includes inner join, left join, right join or full join;
[0113] Step S602: Display the association results of each target database table after the association operation is performed according to the association relationship on the preset data preview interface.
[0114] For example, if there are multiple target database tables, the relationships between different target database tables need to be configured. Users can perform association operations on the target database tables in the data editing interface. After responding to the association operation, the system can determine the relationships between each target database table.
[0115] For example, a user can input information about the specific relationship between tables, such as inner join, left join, right join, or full join. After receiving the user's input, the system can determine whether the relationship between the tables is an inner join, left join, right join, or full join.
[0116] Users can perform association operations on various target database tables. Finally, in this embodiment of the application, the association results obtained after the association operations on various target database tables are performed according to the association relationship can be displayed on a preset data preview interface.
[0117] Please see Figure 8In some embodiments, step S602 may include steps S701 to S702:
[0118] Step S701: If all target database tables come from the same database, use a preset query statement to query the target database tables of the same database, and display the association results obtained by performing association operations on each target database table according to the association relationship on the preset data preview interface.
[0119] Step S702: If the target database tables come from different databases, a soft connection between the different databases is created uniformly through a preset connection creation function, and an alias is returned to point to the different database connections. The target database tables of the different databases are queried according to the alias and the preset standard query statement. The association results of each target database table after the association operation is performed according to the association relationship are displayed on the preset data preview interface.
[0120] For example, if there are multiple target database tables, table associations are divided into the following two categories: single database multi-table association and multi-database multi-table association. For the above two cases, the backend processing logic is different, and the implementation methods are also diverse.
[0121] If all target database tables come from the same database, the table relationship is a single-database, multi-table relationship. In this case, the system can use preset query statements to query multiple tables in the specified database. These tables are target database tables from the same database. After determining the relationship based on the user-selected association fields and join method, the system selects the correct keyword to perform the table join operation, and then displays the corresponding join results in the data preview interface.
[0122] If the target database tables come from different databases, the table relationships are multi-database, multi-table relationships. In this case, when a user selects tables from different databases to join, a symbolic connection to the target database can be created uniformly using the connection creation function. This returns an alias for the connection, which points to different types of databases such as MySQL, SQL Server, PostgreSQL, and Oracle. Based on the alias and preset standard query statements, the target database tables in different databases are queried, and then the join operation is performed using the standard query statements. The corresponding join results are then displayed in the data preview interface.
[0123] Please see Figure 9 In some embodiments, step S105 may further include steps S801 to S802:
[0124] Step S801: In response to the confirmation operation of the result display, perform a join operation on the target database table based on the join result to obtain the target data;
[0125] Step S802: Convert the target data into a chart and display the chart on a preset data visualization interface. The chart may include a line chart, a bar chart, or a pie chart.
[0126] For example, in the embodiments of this application, the generated analysis dataset can be visualized, the dense two-dimensional table data can be automatically summarized according to certain rules, and the target data to be displayed can be converted into a chart form and presented in a three-dimensional and intuitive chart form.
[0127] For example, the chart generation process can be performed in the background. Specifically, after the user confirms the display of results, the background will perform a join operation on the target database table based on the associated results to obtain the target data. The format of the target data has been described in the above embodiments and will not be repeated here.
[0128] For example, in the embodiments of this application, the target data can be converted into charts. There are various types of visualization charts, such as line charts, bar charts, or pie charts. Specifically, a line chart can convert data from the same table or different tables into a curve, allowing users to understand the fluctuations in the data through the changes in the curve; or a bar chart can convert data from the same table or different tables into bars, allowing users to understand the size of the data through the height of the bars; or a pie chart can convert data from the same table or different tables into data under a corresponding pie chart, such as converting all data within a table into a pie chart, or converting related data from different tables into a pie chart, allowing users to understand the proportion of each data point under the pie chart.
[0129] Please see Figure 10 In some embodiments, step S802 may include steps S901 to S903:
[0130] Step S901: Analyze the field type of each target field in the target data, and determine whether each target field is an initial dimension field or an initial metric field according to the field type. Dimensions represent the perspective of analysis, and metrics represent quantifiable indicators.
[0131] Step S902: Obtain the preset display rules, and determine the target dimension field or target metric field for visualization from the initial dimension field or initial metric field according to the display rules;
[0132] Step S903: Determine the chart type based on the target dimension field and the target metric field, and display the chart of the target data under the chart type in the preset data visualization interface.
[0133] For example, in this embodiment of the application, the user only needs to click the visualization button and complete the confirmation operation to generate a chart with one click, and the background performs the visualization processing flow.
[0134] Specifically, the backend visualization process includes first analyzing the type of each field in the data to determine whether it is a dimension field or a measure field. Understandably, subsequent filtering of dimension fields or measure fields is required. Therefore, in this embodiment, the data initially obtained from the target data is referred to as the initial dimension field or initial measure field. Here, dimension refers to the analytical perspective, while measure refers to a quantifiable indicator.
[0135] Subsequently, embodiments of this application can obtain preset display rules, and filter dimension fields or measurement fields through display rules so that the filtered target dimension fields or target measurement fields meet the actual requirements, which ultimately helps in the generation of charts.
[0136] Therefore, after determining the target dimension field or target metric field for visualization from the initial dimension field or initial metric field according to the display rules, this embodiment of the application determines the chart type based on the target dimension field and the target metric field, and displays the chart of the target data under the chart type on the preset data visualization interface.
[0137] Please see Figure 11 In some embodiments, step S902 may include steps S1001 to S1003:
[0138] Step S1001: Perform deduplication calculation on each initial dimension field or initial metric field to obtain the number of different values under the corresponding field;
[0139] Step S1002: Obtain the total number of records of the target data, and calculate the percentage based on the number of different values under the corresponding field and the total number of records to obtain the corresponding percentage value;
[0140] Step S1003: Determine the initial dimension field with the largest percentage value as the default target dimension field, or determine the initial measure field with the smallest percentage value as the default target measure field.
[0141] For example, in determining the visualization dimension or metric, filtering can be performed according to pre-defined display rules. Specifically, if multiple dimensions and metrics exist (i.e., multiple initial dimension fields or initial metric fields), the target dimension field or target metric field for visualization is selected based on the rules. Conversely, if no initial dimension field or initial metric field meets the display rules, it can be directly determined as the target dimension field or target metric field.
[0142] Specifically, based on the above analysis result set, this embodiment of the application performs deduplication calculation on each field to obtain the number of different values under the corresponding field, i.e., num[field name]. For example, it obtains how many different values are under the initial dimension field or the initial measure field. If the name field is deduplicated to obtain Zhang San, Li Si, and Wang Wu, then the name field has 3 values. Then, the total number of records of the target data (count) is obtained, and the two are calculated as a percentage using the formula: percentage (percentage value) = num[field name] / count * 100%, finally obtaining the corresponding percentage value (percent). It can be understood that the percentage value obtained will be different under different measures or fields.
[0143] Furthermore, in this embodiment, the target metric field with the largest percent value is used as the default metric field to obtain the target dimension field, and the target dimension field with the smallest percent value is used as the default target dimension field. It is understood that the above is only one method for generating charts provided in this embodiment; charts can also be generated in other ways while meeting the requirements of this embodiment.
[0144] In addition, for the obtained initial dimension fields or initial measure fields, this application embodiment can also determine whether they need to be summarized and calculated, and set an upper limit for the summary during the summary calculation process. If the total number of data records is greater than the upper limit, the summary is performed; otherwise, the summary is not performed.
[0145] Additional notes regarding the aforementioned upper limit: This upper limit is configurable. Users can modify the backend configuration file based on the frontend display effect to ensure the effectiveness or display quality of the visualization. For example, when the upper limit is set to 5, if the total number of records in the visualized data is less than 5, it will be marked as not summarized (N); otherwise, it will be marked as summarized (Y).
[0146] This application also provides an embodiment. The above-described process of generating the required chart by judging dimensions and metrics can be understood as an automatic chart generation process. In addition, this application embodiment can also intelligently recommend charts matching the user's identity identifier by incorporating the user's identity identifier.
[0147] In practical applications, the database-based data display system proposed in this embodiment can serve as a public system, allowing different users to log in and query database chart information. However, different users have different expectations regarding the format of the charts they wish to see. For example, in one industry, users might prefer a pie chart to show the proportion of data within the overall picture; in another industry, they might prefer a line chart to show the trend of data changes; and in yet another industry, they might prefer a bar chart to show the scattered changes in data. Therefore, users in different industries have different requirements for the data display of the queried database charts.
[0148] Based on this, refer to Figure 12 In some embodiments, step S802 may further include steps S1101 to S1105:
[0149] Step S1101: Obtain the user's identity information;
[0150] Step S1102: Match the corresponding recommendation probability based on the identity information, and generate the first chart based on the recommendation probability and the target data;
[0151] Step S1103: Convert the target data into a second chart;
[0152] Step S1104: If the first chart and the second chart are of different types, display the chart selection interface;
[0153] Step S1105: In response to the chart selection operation, the target chart is displayed in the preset data visualization interface.
[0154] The identity information can represent the user's industry and is the user's identity ID. It is understood that a backend database can be constructed in this embodiment, containing information on different professions. Users will pre-register an account in the system and select the corresponding profession information. After the system obtains the user's identity information, it can look up the corresponding recommendation probability in a table.
[0155] The first chart is generated directly from the target data after incorporating the recommendation probability. The second chart is automatically generated by combining dimensions and metrics as described in the previous embodiment. It can be understood that when the recommendation probability is greater than a preset threshold (representation result is yes), the first chart is generated based on the recommendation probability and target data; otherwise, it is not generated. The target chart is selected from the first and second charts based on the user's chart selection action and is used for the final display.
[0156] The type of the first and second charts refers to whether they are pie charts, line charts, or bar charts. For example, if the first chart is a pie chart and the second chart is a line chart, then they are different types.
[0157] For example, the recommendation probability is the probability of recommending a particular chart for different professions. This recommendation probability can be generated based on historical data. Specifically, the system can store historical data queries and record the number of times users selected a chart for each different profession, generating probabilities accordingly. Understandably, each time the system presents a chart selection pop-up window when the types of the first and second charts differ, the system records each chart selection and adjusts the recommendation probability based on the user's choice.
[0158] For example, if a user chooses the second chart instead of the recommended first chart in a given selection of the first and second charts, the system will decrease the recommendation probability, indicating that users in that profession tend to choose the charts generated by the system's intelligent judgment. After multiple historical samples have selected the first chart, the recommendation probability will be less than a preset threshold, and the system will no longer recommend charts to users in that profession. Conversely, if a user chooses the first chart instead of the second chart, the recommendation probability will increase, indicating that users in that profession are accustomed to using charts commonly used in the industry.
[0159] Understandably, the recommendation probability changes dynamically. The system will intelligently adjust the recommendation probability based on historical query results to achieve intelligent database data querying.
[0160] The above embodiments take mapping identity information to a certain occupation as an example. Under the premise of meeting the requirements of the embodiments of this application, identity information can also be mapped to an individual, that is, the recommendation probability can be adjusted according to the individual's chart selection habits. No specific restrictions are made here.
[0161] Please see Figure 13 This application also provides a database-based data display system that can implement the above-described database-based data display method. The database-based data display system includes:
[0162] The data source module 1301 is used to respond to the database addition operation and display the initial basic information of the database in the preset data source interface;
[0163] The data source module 1301 is also used to display the initial database table under the target basic information in the data source interface in response to the first selection operation for the database, wherein the target basic information is selected from the initial basic information;
[0164] The data editing module 1302 is used to display the target database table in a preset data editing interface in response to a second selection operation on the initial database table, wherein the target database table is selected from the initial database table;
[0165] The data preview module 1303 is used to display the association result of the target database table in a preset data preview interface in response to the association operation on the target database table if there are multiple target database tables.
[0166] The data visualization module 1304 is used to display target data in a preset data visualization interface in response to the confirmation operation of the result display. The target data is generated by the target database table after the association operation is completed by combining the association results.
[0167] In addition, this application embodiment may also include a data filtering module 1305 for performing the filtering steps in the above embodiment, which will not be described in detail here.
[0168] For example, the database-based data display system in this application embodiment can execute the database-based data display method described in the above embodiments.
[0169] The data source interface is specifically designed to display basic information about the database. Different databases can be referred to as data sources. Both the initial basic information and the target basic information are fundamental database information, which may include the database's name, type, source, and size. This basic information provides an understanding of the database's basic characteristics.
[0170] Adding a database can be a user input operation on the display screen. For example, the screen could show a database configuration input interface or a database selection interface, where the user can input database addition commands and select the database to be displayed on the data source interface. For instance, adding a database can be an input operation for database information or a selection operation for information displayed on the interface; no specific limitations are imposed here.
[0171] The initial basic information is the basic information of the corresponding database. Different databases have different initial basic information. That is, the initial basic information represents the basic information of each database before the selection is made.
[0172] When executing the method, the system can first display the data source interface on the display screen, and the user can perform database addition operations on the data source interface. In response to the operation, the system performs a database query in the backend, returns the initial basic information of the database to be added, and displays it on the data source interface.
[0173] The target basic information is one or more of the initial basic information selected after the initial basic information is selected. The word "target" represents the selection.
[0174] The initial database table is a table that displays form information from the corresponding database after the user selects one or more target basic information. For example, the initial database table displayed on the data source interface contains basic information such as the table name, table source, and table size. It's understandable that a database may contain multiple tables, therefore each database may have multiple initial database tables.
[0175] The first selection operation is the user's selection on the data source interface. This operation allows them to select the database to be visualized. Essentially, the user can complete the first selection by clicking on an item related to the initial basic information of a database, thus identifying that database as the target database. It's also understood that if multiple first selection operations are performed, multiple target databases will be selected, resulting in multiple sets of target basic information, and these target databases can be of different types.
[0176] For example, users can add one or more associated databases, select the database type, and the connection parameter list will automatically switch according to the type. Users fill in the parameters required for a successful database connection, connect to the specified database server, and complete the addition of associated databases in sequence. After the addition is completed, multiple databases are displayed in a list on the data source interface on the left side of the window. Double-clicking a database displays all the tables under that database.
[0177] The data editing interface is a dedicated interface for editing data. For example, the display screen can show the data editing interface, through which users can perform configuration operations for linking different tables. The interface also displays the selected target database table, allowing users to visualize and clearly identify the currently selected table. No specific limitations are imposed here.
[0178] The second selection operation is a selection performed by the user on the data source interface, or between the data source interface and the data editing interface. Through this second selection operation, the target database table to be visualized can be selected. Understandably, users can complete the second selection operation by clicking, such as clicking on the initial database table under a specific database to confirm that the initial database table is the target database table. Alternatively, the second selection operation can also be a drag-and-drop operation; users can click on an initial database table in the data source area and drag it to the data editing interface.
[0179] The target database table is a database table selected after choosing from the initial database tables; the term "target" indicates that it has been selected. For example, the target database table displayed in the data editing interface includes basic information such as the table name, table source, and table size. It is understandable that if the user makes multiple second selections, there will be multiple selected target database tables, which can come from the same database or different databases.
[0180] The data preview interface is specifically designed for previewing data. For example, a display screen can show the data preview interface, allowing users to preview detailed information about database tables or the join relationships between multiple database tables. This ensures that the data to be displayed meets user requirements before the final data is shown.
[0181] Association operations can be either inputting or selecting association information. Association, also known as connection, refers to the relationship between database tables. These operations configure associations between selected target database tables. For example, if the association operation is an input operation, the user enters the association information between the target database tables, and the system performs the association operation based on the user's input. If the association operation is a selection operation, the screen displays options for the connection relationships between the target database tables; the user clicks "OK" or selects an option to obtain the association relationship.
[0182] It should be noted that, for multi-table scenarios, this embodiment of the application defaults to using fields with the same name in each table to determine the relationship, and defaults to determining an inner join relationship based on fields with the same name in the tables. Therefore, the join operation can also be a join confirmation operation, where users can click "Confirm" to select the automatically generated join relationship. In addition, after the system defaults to selecting the join relationship, users can manually switch the join fields and join methods to determine other join relationships, without specific restrictions here.
[0183] The association result can be a description of the relationship between database tables. For example, if table A and table B are target database tables, the association result can be "table A and table B have an inner join relationship". In addition, the association result can also be detailed information obtained by combining the target database tables after the association relationship, without specific restrictions.
[0184] A data visualization interface is a dedicated interface for displaying results. For example, a display screen can show a data visualization interface, and a data preview interface can show detailed information between target database tables, completing the display of query results. Users can understand the information they need to query through the data visualization interface, which helps them to intuitively observe information and facilitates subsequent data analysis.
[0185] The confirmation operation can be done by clicking the confirmation button. The screen displays an option to confirm or not. After previewing the selected target database table and the corresponding related results in the data preview interface, if the user believes that the information meets the query requirements, they can click the confirmation option in the interface to complete the confirmation operation.
[0186] Target data is the data generated after the target database table completes the join operation by combining the join results. It can be understood that target data can be detailed information about the target database table, including the content details of each table, the relationship between multiple tables, etc.
[0187] Understandably, the data preview interface can also display the target data generated after combining the results of the association with the target database table. Understandably, the target data displayed in the data preview interface is different from the target data displayed in the database visualization interface. The data preview interface can display a rough result, that is, the result before the data has been formatted or beautified, or it can be an overview of the details in the table. On the other hand, the target data displayed in the data visualization interface can be the final result presented to the client, which can be the result after the data has been formatted or beautified, making it more convenient for users to view.
[0188] In response to the confirmation operation of the result display, the target data is displayed in the preset data visualization interface. The target data is generated by the target database table after the association operation is completed in combination with the association results.
[0189] This application simplifies data querying in databases. When dealing with multiple databases and tables, there's no need to understand the query languages of different databases. Relevant information is displayed visually, and users complete form selection and association through simple human-computer interaction, ultimately displaying the required data. This significantly reduces the operational cost for users. Previously, different types of databases required programming languages to complete table associations and configurations, with varying configuration requirements between tables, further increasing the cost of query analysis. This application simplifies the display of forms from heterogeneous databases through visualization. Only simple human-computer interaction is required on the front end, while form querying and association configuration are completed on the back end. Users do not need to concern themselves with the backend processing logic, greatly improving system usability. Therefore, this application significantly improves data query efficiency and reduces data query costs.
[0190] The specific implementation of this database-based data display system is basically the same as the specific embodiments of the database-based data display method described above, and will not be repeated here. While meeting the requirements of the embodiments of this application, the database-based data display system may also be equipped with other functional modules to implement the database-based data display method in the above embodiments.
[0191] This application also provides an electronic device, which includes a memory and a processor. The memory stores a computer program, and the processor executes the computer program to implement the aforementioned database-based data display method. This electronic device can be any smart terminal, including tablet computers, in-vehicle computers, etc.
[0192] Please see Figure 14 , Figure 14 The hardware structure of an electronic device according to another embodiment is illustrated. The electronic device includes:
[0193] The processor 1401 can be implemented using a general-purpose CPU (Central Processing Unit), microprocessor, application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this application.
[0194] The memory 1402 can be implemented as a read-only memory (ROM), a static storage device, a dynamic storage device, or a random access memory (RAM). The memory 1402 can store the operating system and other applications. When the technical solutions provided in the embodiments of this specification are implemented through software or firmware, the relevant program code is stored in the memory 1402 and is called and executed by the processor 1401 to execute the database-based data display method of the embodiments of this application.
[0195] The input / output interface 1403 is used to implement information input and output;
[0196] The communication interface 1404 is used to enable communication and interaction between this device and other devices. Communication can be achieved through wired means (such as USB, Ethernet cable, etc.) or wireless means (such as mobile network, WIFI, Bluetooth, etc.).
[0197] Bus 1405 transmits information between various components of the device (e.g., processor 1401, memory 1402, input / output interface 1403, and communication interface 1404);
[0198] The processor 1401, memory 1402, input / output interface 1403 and communication interface 1404 are connected to each other within the device via bus 1405.
[0199] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the above-described database-based data display method.
[0200] Memory, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs and non-transitory computer-executable programs. Furthermore, memory may include high-speed random access memory, and may also include non-transitory memory, such as at least one disk storage device, flash memory device, or other non-transitory solid-state storage device. In some embodiments, memory may optionally include memory remotely located relative to the processor, and these remote memories can be connected to the processor via a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.
[0201] The embodiments described in this application are for the purpose of more clearly illustrating the technical solutions of the embodiments of this application, and do not constitute a limitation on the technical solutions provided by the embodiments of this application. As those skilled in the art will know, with the evolution of technology and the emergence of new application scenarios, the technical solutions provided by the embodiments of this application are also applicable to similar technical problems.
[0202] Those skilled in the art will understand that the technical solutions shown in the figures do not constitute a limitation on the embodiments of this application, and may include more or fewer steps than shown, or combine certain steps, or different steps.
[0203] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.
[0204] Those skilled in the art will understand that all or some of the steps in the methods disclosed above, as well as the functional modules / units in the systems and devices, can be implemented as software, firmware, hardware, or suitable combinations thereof.
[0205] The terms “first,” “second,” “third,” “fourth,” etc. (if present) in the specification and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms “comprising” and “having,” and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0206] It should be understood that in this application, "at least one (item)" means one or more, and "more than" means two or more. "And / or" is used to describe the relationship between related objects, indicating that three relationships can exist. For example, "A and / or B" can represent three cases: only A exists, only B exists, and both A and B exist simultaneously, where A and B can be singular or plural. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. "At least one (item) of the following" or similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one (item) of a, b, or c can represent: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, and c can be single or multiple.
[0207] In the embodiments provided in this application, it should be understood that the disclosed systems and methods can be implemented in other ways. For example, the system embodiments described above are merely illustrative; for instance, the division of the units described above is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection through some interfaces, devices, or units, and may be electrical, mechanical, or other forms.
[0208] The units described above as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0209] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0210] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes multiple instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of the various embodiments of this application. The aforementioned storage medium includes various media capable of storing programs, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0211] The preferred embodiments of the present application have been described above with reference to the accompanying drawings, but this does not limit the scope of the claims of the present application. Any modifications, equivalent substitutions, and improvements made by those skilled in the art without departing from the scope and substance of the embodiments of the present application shall be within the scope of the claims of the present application.
Claims
1. A database-based data display method, characterized by, The method comprises: in response to a database addition operation, displaying initial basic information of a database in a preset data source interface; in response to a first selection operation on the database, displaying initial database tables under target basic information in the data source interface, wherein the target basic information is selected from the initial basic information; in response to a second selection operation on the initial database tables, displaying target database tables in a preset data editing interface, wherein the target database tables are selected from the initial database tables; if there are multiple target database tables, in response to an association operation on the target database tables, displaying association results of the target database tables in a preset data preview interface; in response to a confirmation operation of the result display, displaying target data in a preset data visualization interface, wherein the target data is generated after the target database tables complete the association operation in combination with the association results; in response to the association operation on the target database tables, displaying the association results of the target database tables in the preset data preview interface, comprising: in response to the association operation on the target database tables, determining the association relationship between each of the target database tables, wherein the association relationship includes inner join, left join, right join or full join; displaying the association results of each of the target database tables after the association operation according to the association relationship in the preset data preview interface; the displaying of the association results of each of the target database tables after the association operation according to the association relationship in the preset data preview interface, comprising: if the target database tables are all from the same database, the association relationship is a single-database multi-table association relationship, a preset query statement is used to query the target database tables of the same database, and the association results of each of the target database tables after the association operation according to the association relationship are displayed in the preset data preview interface; if the target database tables are from different databases, the association relationship is a multi-database multi-table association relationship, a preset connection creation function is used to uniformly create a soft connection between different databases and return an alias for pointing to the connection of different databases, the target database tables of different databases are queried according to the alias and a preset standard query statement, and the association results of each of the target database tables after the association operation according to the association relationship are displayed in the preset data preview interface.
2. The database-based data display method according to claim 1, characterized by, in response to the confirmation operation of the result display, displaying the target data in the preset data visualization interface, comprising: obtaining a filtering rule for filtering information in the target database tables; filtering the information in the target database tables according to the filtering rule, and displaying the filtered information in the target database tables in the data preview interface; in response to the confirmation operation of the result display, displaying the target data in the preset data visualization interface, wherein the target data is generated after the filtered target database tables complete the association operation in combination with the association results.
3. The database-based data display method according to claim 2, characterized by, the obtaining of the filtering rule for filtering the information in the target database tables, comprising: Display a plurality of initial fields and corresponding initial filtering conditions for performing a filtering operation in a preset data filtering interface; In response to a third selection operation on the filtering rule, display a valued target field and a target filtering condition in the data filtering interface, wherein the target field is selected from the initial fields and is obtained after being valued, and the target filtering condition is selected from the initial filtering conditions; Display the filtering rule obtained based on the target field and the target filtering condition in the data filtering interface.
4. The database-based data display method according to claim 2, characterized by, The method further comprises: Display a data visualization window; Divide the data visualization window into a first display area, a second display area and a third display area in sequence according to functions, wherein the first display area is used to display the data source interface, the second display area is used to display the data editing interface and the data filtering interface, and the third display area is used to display the data preview interface and the data visualization interface.
5. The database-based data display method according to claim 1, characterized by, If the target database table is only one, the method further comprises: Query the target database table using a preset query statement, and display detailed information corresponding to the target database table in a preset data preview interface; In response to a confirmation operation of the result display, display the detailed information in a preset data visualization interface.
6. The database-based data display method according to claim 1, wherein In response to the confirmation operation of the result display, display target data in the preset data visualization interface, comprising: In response to the confirmation operation of the result display, perform an association operation on the target database table in combination with the association result to obtain target data; Convert the target data into a chart, and display the chart in the preset data visualization interface, wherein the chart includes a line chart, a column chart or a pie chart.
7. The database-based data display method according to claim 6, wherein The conversion of the target data into a chart comprises: Analyze the field type of each target field in the target data, and determine whether each target field is an initial dimension field or an initial measurement field according to the field type, wherein the dimension represents the angle of analysis, and the measurement represents a quantifiable index; Obtain a preset display rule, and determine visualized target dimension fields and target measurement fields from the initial dimension fields and the initial measurement fields according to the display rule; Determine a chart type according to the target dimension fields and the target measurement fields, and display a chart of the target data in the chart type in a preset data visualization interface.
8. The database-based data display method according to claim 7, wherein, Under the display rule, the determination of the visualized target dimension fields and the target measurement fields from the initial dimension fields and the initial measurement fields comprises: Perform a deduplication calculation on each initial dimension field or initial measurement field to obtain the number of different values under the corresponding field; Obtain the total number of records of the target data, and perform a percentage calculation according to the number of different values under the corresponding field and the total number of records to obtain a corresponding percentage value; Determine the initial dimension field with the largest percentage value as the default target dimension field, or determine the initial measurement field with the smallest percentage value as the default target measurement field.
9. A database-based data display system, characterized by The system comprises: The data source module is configured to display initial basic information of the database in a preset data source interface in response to a database addition operation. The data source module is further configured to display initial database tables under target basic information in the data source interface in response to a first selection operation on the database, wherein the target basic information is selected from the initial basic information. The data editing module is configured to display target database tables in a preset data editing interface in response to a second selection operation on the initial database tables, wherein the target database tables are selected from the initial database tables. The data preview module is configured to display association results of the target database tables in a preset data preview interface in response to an association operation on the target database tables if the target database tables are multiple. The data visualization module is configured to display target data in a preset data visualization interface in response to a confirmation operation of the result display, wherein the target data is generated after the target database tables complete the association operation in combination with the association results. The data preview module is configured to display association results of the target database tables in a preset data preview interface in response to an association operation on the target database tables, including: The data preview module is configured to display association results of the target database tables in a preset data preview interface in response to an association operation on the target database tables, including: The data preview module is configured to display association results of the target database tables in a preset data preview interface in response to an association operation on the target database tables, including: If the target database tables are all from the same database, the association relationship is a single-database multi-table association relationship, a preset query statement is used to query the target database tables of the same database, and the association results of the target database tables after the association operation according to the association relationship are displayed in the preset data preview interface. If the target database tables are from different databases, the association relationship is a multi-database multi-table association relationship, a preset connection creation function is used to uniformly create a soft connection between different databases and return an alias for pointing to the connection of different databases, the target database tables of different databases are queried according to the alias and a preset standard query statement, and the association results of the target database tables after the association operation according to the association relationship are displayed in the preset data preview interface. The electronic device includes a memory and a processor, the memory stores a computer program, and the processor implements the database-based data display method of any one of claims 1 to 8 when executing the computer program.
10. An electronic device, comprising: The computer program is executed by the processor to implement the database-based data display method of any one of claims 1 to 8.
11. A computer readable storage medium, the storage medium having stored thereon a computer program, characterized in that,
Citation Information
Patent Citations
Data visual query method and device, electronic equipment and storage medium
CN114385721A