Code-free processing method and system for data in iron and steel industry
By providing code-free processing methods and systems in the steel industry data governance, users can automatically generate SQL instructions through simple page operations, solving the time-consuming and flexibility problems of manual writing of SQL statements, and improving the efficiency of data governance and the autonomy of business departments.
Patent Information
- Application Number
- CN202510004360.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-02
- Publication Date
- 2025-04-25
AI Technical Summary
It is difficult to manually write SQL statements for data governance, it takes a long time and cannot meet business needs in a timely manner, and it is difficult for non-technical personnel to participate in indicator development and maintenance, which limits the autonomy and flexibility of the business department.
It provides a method and system for processing data without code in the steel industry. By responding to selection instructions for selection indicators, it generates corresponding operation interfaces, receives user input instructions to generate SQL instructions, calls preset configuration data to generate target data, and displays target data in the data output box.
Through the codeless processing method and system, users can automatically generate SQL instructions corresponding to the input instructions, quickly complete the calculation and generation of complex indicators, solve the time-consuming and flexibility of manually writing SQL statements, and improve the efficiency of data governance and the autonomy of business departments.
Smart Images

Figure CN119884153A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of data governance in the steel industry, and specifically to a method and system for code-free processing of data in the steel industry. Background Art
[0002] In the steel industry, data governance and business analysis are of great significance for optimizing production processes, improving product quality and enhancing market competitiveness. Therefore, in the steel industry, data processing through SQL writing by technicians can integrate complex data, or process duplicates, wrong values and incomplete records in the data, improve data instructions, or use SQL to perform complex data analysis, such as aggregation, sorting and filtering, to discover trends and patterns in the production process.
[0003] However, data governance and business analysis rely on technical personnel to write complex SQL statements and process data. Technical personnel manually write SQL statements and process data, which takes a long time and cannot meet the needs of business departments in a timely manner. In addition, due to the lack of professional data analysis skills, non-technical personnel find it difficult to participate in the development and maintenance of indicators, which limits the autonomy and flexibility of business departments. When faced with market changes or business adjustments, it is difficult to quickly update and adjust the indicator system when manually writing SQL statements for data governance and business analysis, which affects production. Summary of the invention
[0004] The present application provides a method and system for code-free data processing in the steel industry to solve the problem that it is difficult to manually write SQL statements for data management.
[0005] In a first aspect, the present application provides a method for code-free processing of data in the steel industry, comprising:
[0006] In response to a selection instruction for selecting an indicator type, an operation interface corresponding to the indicator type is generated according to the indicator type; the operation interface includes a plurality of data input boxes, an indicator list and a data output box;
[0007] Receiving an input instruction input by a user based on the data input box and the indicator list, and generating an SQL instruction;
[0008] Based on the SQL instruction, calling preset configuration data to generate target data;
[0009] The target data is displayed in the data output frame.
[0010] Optionally, the indicator types include atomic indicators, derived indicators and composite indicators;
[0011] The operation interface includes a first operation interface corresponding to the atomic indicator, a second operation interface corresponding to the derived indicator, and a third operation interface corresponding to the composite indicator.
[0012] Optionally, if the operation interface is the first operation interface, receiving an input instruction input by a user based on the data input box and the indicator list, and generating an SQL instruction includes:
[0013] Obtaining field data in the data input box;
[0014] Acquire a first operation of a user based on the indicator list, and select a detailed table and a calculation function from the indicator list according to the first operation; the field data is a field of data in the detailed table;
[0015] Obtaining an atomic expression according to the field data, the detail table and the calculation function;
[0016] The SQL instruction is generated according to the atomic expression.
[0017] Optionally, if the operation interface is the second operation interface, receiving an input instruction input by a user based on the data input box and the indicator list, and generating an SQL instruction includes:
[0018] Obtaining the atomic expression in the data input box;
[0019] Acquire a second operation of the user based on the indicator list, and select a general limiting condition, a time limiting condition, and a statistical dimension from the indicator list according to the second operation; the statistical dimension is the dimension data stored in the dimension table;
[0020] Constructing a first SQL syntax tree according to the atomic expression, the general limiting condition, the time limiting condition, and the statistical dimension;
[0021] The SQL instruction is generated according to the first SQL syntax tree.
[0022] Optionally, constructing a first SQL syntax tree according to the atomic expression, the general limiting condition, the time limiting condition, and the statistical dimension includes:
[0023] Constructing an initial SQL syntax tree; the initial SQL syntax tree includes a SELECT clause, a FROM clause, a WHERE clause, and a GROUP-BY clause;
[0024] Add the statistical dimension to the GROUP-BY clause;
[0025] Adding the time qualification condition to the WHERE clause;
[0026] According to the general limiting condition, a plurality of the WHERE clauses are spliced according to the logical relationship; the general limiting condition includes two logical calculations of AND and OR;
[0027] Adding the atomic expression and the statistical dimension to a SELECT clause;
[0028] The GROUP-BY clause, the WHERE clause, and the SELECT clause are combined to obtain a first SQL syntax tree.
[0029] Optionally, if the operation interface is a third operation interface, receiving an input instruction input by a user based on the data input box and the indicator list, and generating an SQL instruction includes:
[0030] Obtain the statistical dimension in the data input box;
[0031] Acquire a third operation of the user based on the indicator list, and select a plurality of the first SQL syntax trees from the indicator list according to the third operation;
[0032] Constructing a second SQL syntax tree according to the first SQL syntax tree and the statistical dimension;
[0033] The SQL instruction is generated according to the second SQL syntax tree.
[0034] Optionally, constructing a second SQL syntax tree according to the first SQL syntax tree and the statistical dimension includes:
[0035] According to the statistical dimension, performing a JOIN calculation on the first SQL syntax tree to obtain a FROM clause;
[0036] The FROM clause is mapped to output fields of the SELECT clause to obtain a second SQL syntax tree.
[0037] Optionally, based on the SQL instruction, calling preset configuration data to generate target data includes:
[0038] Obtaining the operation type keyword in the SQL instruction;
[0039] According to the operation type keyword, determining a target data table in the preset configuration data; the target data table includes a detail table and a dimension table corresponding to the operation type keyword;
[0040] The target data table is operated according to the SQL instruction to obtain target data.
[0041] In a second aspect, the present application provides a system for processing data without code in the steel industry, which is applied to the method for processing data without code in the steel industry described in the first aspect, and includes: a display module and a data processing module;
[0042] The data processing module is used to generate an operation interface corresponding to the indicator type according to the indicator type when receiving a selection instruction for selecting an indicator type; the operation page includes a plurality of data input boxes, an indicator list and a data output box;
[0043] Receiving an input instruction input by a user based on the data input box and the indicator list, and generating an SQL instruction;
[0044] Based on the SQL instruction, calling preset configuration data to generate target data;
[0045] The display module is used to display the target data in the data output frame.
[0046] It can be seen from the above technical solutions that the present application provides a method and system for code-free data processing in the steel industry, the method comprising: in response to a selection instruction for selecting an indicator type, generating an operation interface corresponding to the indicator type according to the indicator type; the operation page comprises a number of data input boxes, an indicator list and a data output box; receiving an input instruction input by a user based on the data input box and the indicator list, generating an SQL instruction; based on the SQL instruction, calling preset configuration data to generate target data; and displaying the target data in the data output box. By inputting the required instructions in the input box and the indicator list of the operation page, the corresponding SQL instructions can be automatically generated, that is, the calculation and generation of complex indicators can be completed through simple page operations, so as to solve the problem that it is difficult to manually write SQL statements for data management. BRIEF DESCRIPTION OF THE DRAWINGS
[0047] In order to more clearly illustrate the technical solution of the present application, the drawings required for use in the embodiments are briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0048] Figure 1 A flow chart of the method for processing data without coding in the steel industry provided in the embodiment of the present application;
[0049] Figure 2 A schematic diagram of the home page of the operation page provided in the embodiment of the present application;
[0050] Figure 3 A schematic diagram of a first operation interface provided in an embodiment of the present application;
[0051] Figure 4A schematic diagram of a second operation interface provided in an embodiment of the present application;
[0052] Figure 5 A schematic diagram of general limiting conditions of the second operation interface provided in an embodiment of the present application;
[0053] Figure 6 A schematic diagram of a third operation interface provided in an embodiment of the present application;
[0054] Figure 7 Schematic diagram of the steel industry data code-free processing system provided in an embodiment of the present application. DETAILED DESCRIPTION
[0055] The following embodiments are described in detail, and examples thereof are shown in the accompanying drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The implementations described in the following embodiments do not represent all implementations consistent with the present application. They are only examples of systems and methods consistent with some aspects of the present application as detailed in the claims.
[0056] In the steel industry, data governance and business analysis are of great significance for optimizing production processes, improving product quality and enhancing market competitiveness.
[0057] In some embodiments, in the steel industry, data processing by technicians writing SQL can integrate complex data together, or handle duplicates, error values, and incomplete records in the data, improve data instructions, or use SQL to perform complex data analysis such as aggregation, sorting, and filtering to discover trends and patterns in the production process.
[0058] However, data governance and business analysis rely on technical personnel to write complex SQL statements and process data. Technical personnel manually write SQL statements and process data, which takes a long time and cannot meet the needs of business departments in a timely manner. In addition, due to the lack of professional data analysis skills, non-technical personnel find it difficult to participate in the development and maintenance of indicators, which limits the autonomy and flexibility of business departments. When faced with market changes or business adjustments, it is difficult to quickly update and adjust the indicator system when manually writing SQL statements for data governance and business analysis, which affects production.
[0059] In order to solve the problem that it is difficult to manually write SQL statements for data management, some embodiments of this application provide a method for processing data in the steel industry without code, see Figure 1 , the code-free processing methods for data in the steel industry specifically include:
[0060] S100: In response to a selection instruction for selecting an indicator type, generating an operation interface corresponding to the indicator type according to the indicator type;
[0061] Among them, Figure 2 As shown, Figure 2 A schematic diagram of the home page of the operation page provided for the embodiment of the present application; the embodiment of the present invention can respond to the user's selection instruction, and according to the selection instruction, generate an operation interface corresponding to the selection instruction, wherein the indicator types include atomic indicators, derived indicators, and composite indicators; the operation interface includes a first operation interface corresponding to the atomic indicator, a second operation interface corresponding to the derived indicator, and a third operation interface corresponding to the composite indicator. Specifically, when the user's selection instruction selects an atomic indicator, a corresponding first operation interface is generated, when the user's selection instruction selects a derived indicator, a corresponding second operation interface is generated, and when the user's selection instruction selects a composite indicator, a corresponding third operation interface is generated.
[0062] It is understandable that the first operation interface corresponding to the atomic indicator can process data based on the fields in a single data table, which is usually calculated based on clearly defined variables or measurement standards. For example, query the daily steel production through the first operation interface. The daily steel production directly reflects the total amount of steel produced in a certain day and is a basic measurement value that cannot be further divided.
[0063] The second operation interface corresponding to the derived indicator is to add limiting conditions and statistical dimensions on the basis of the first operation interface, and then process the data, that is, to obtain it through mathematical operations, weighting or other conversion processes on the atomic indicators. For example, if the daily steel production is taken as the atomic indicator, then the monthly steel production growth rate is a derived indicator. The monthly steel production growth rate is the growth rate calculated by comparing the steel production of this month with that of the previous month, thus providing a more in-depth and multi-dimensional analysis. Among them, time is the statistical dimension.
[0064] The third operation interface corresponding to the composite index is based on the second operation interface. Atomic indicators and derived indicators can be selected. After selecting the statistical dimension, the relationship between several derived indicators and several atomic indicators can be comprehensively analyzed. That is, the composite index is composed of multiple atomic indicators or derived indicators, which are used to measure the overall performance of the enterprise or the achievement of specific strategic goals. For example, when it is necessary to obtain the production efficiency index, since the production efficiency index includes the comprehensive consideration of multiple atomic indicators or derived indicators such as steel output, energy consumption, and raw material utilization, by integrating multiple atomic indicators or multiple derived indicators, the production efficiency and resource utilization of steel enterprises can be comprehensively evaluated.
[0065] S200: receiving an input instruction input by a user based on a data input box and an indicator list, and generating an SQL instruction;
[0066] When the user completes the selection in the data input box and the indicator list, the SQL command can be automatically generated, wherein the first operation interface, the second operation interface and the third operation interface have different processes for generating the SQL command according to the content input by the user.
[0067] Specifically, in some embodiments, if the operation interface is the first operation interface, receiving an input instruction input by a user based on the data input box and the indicator list, and generating an SQL instruction includes:
[0068] Get the field data in the data input box;
[0069] Acquire the first operation of the user based on the indicator list, and select a detailed table and a calculation function from the indicator list according to the first operation; the field data is a field of the data in the detailed table;
[0070] Get the atomic expression based on the field data, detail table and calculation function;
[0071] Generate SQL instructions based on atomic expressions.
[0072] like Figure 3 As shown, Figure 3 It is a schematic diagram of the first operation interface, wherein the first operation interface is provided with an index list for selecting a detailed list and an index list for selecting a function. After selecting the corresponding detailed list and aggregate function through the index list, the corresponding field data can be selected to obtain an atomic expression, wherein the atomic expression is the function name {field data (detailed list)}; and then the SQL instruction is generated according to the atomic expression. For example, when it is necessary to calculate the total amount of blast furnace iron output, the aggregate function SUM() can be selected through the index list, and the detailed list containing the blast furnace iron output data can be selected. Finally, after selecting the field corresponding to the blast furnace iron output, the atomic expression SUM{blast furnace iron output (production detailed list)} can be obtained; assuming that the name of the production detailed list is production_details; the field name of the blast furnace iron output is high_furnace_iron_output, then according to the atomic expression, the SQL instruction can be obtained as follows:
[0073] SELECT SUM(high_furnace_iron_output)AS total_high;
[0074] FROM production_details;
[0075] Among them, SELECT SUM(high_furnace_iron_output) indicates that the SUM function is used to calculate the sum of the blast furnace iron output field;
[0076] AS total_high means that the calculation result is named total_high;
[0077] FROM production_details specifies to obtain data from the production details table.
[0078] That is, after the user fills in the field data, the detailed table, and selects the calculation function in the first operation interface, the SQL command can be automatically generated, which is convenient and fast. It can be understood that after obtaining the total amount of blast furnace iron output, the total amount of blast furnace iron output can be stored in the summary table, so that the total amount of blast furnace iron output can be directly obtained from the summary table later.
[0079] Among them, it should be noted that after the atomic indicator is configured, since the atomic indicator involves the generation of subsequent derivative indicators and compound indicator calculation logic, that is, the derived indicators and compound indicators need to call the atomic indicator, when the atomic indicator is modified, the subsequent derived indicator generation and compound indicator generation need to be modified. Therefore, the atomic expression can be implemented with a single calculation logic without editing complex calculations.
[0080] In some embodiments, if the operation interface is the second operation interface, receiving an input instruction input by a user based on the data input box and the indicator list, and generating an SQL instruction includes:
[0081] Get the atomic expression in the data input box;
[0082] Acquire a second operation of the user based on the indicator list, and select a general limiting condition, a time limiting condition, and a statistical dimension from the indicator list according to the second operation; the statistical dimension is the dimension data stored in the dimension table;
[0083] Construct a first SQL syntax tree according to the atomic expression, the general qualification condition, the time qualification condition, and the statistical dimension;
[0084] Generate an SQL instruction according to the first SQL syntax tree.
[0085] like Figure 4 As shown, Figure 4It is a schematic diagram of the second operation interface; wherein, the second operation interface is also provided with an indicator list for selecting atomic indicators, an indicator list for selecting time limitation conditions, an indicator list for selecting general limitation conditions and an indicator list for selecting statistical dimensions. For example, when the user wants to calculate the total amount of blast furnace iron output in 2023, the user can select the total amount of blast furnace iron output in the indicator list for selecting atomic indicators, select 2023-2024 in the indicator list for selecting time limitation conditions, and select field data of multiple detailed tables in the indicator list for selecting statistical dimensions to associate multiple tables together. Finally, in the indicator list for general limitation conditions, select the general limitation conditions, and combine the calculation conditions through the two logical calculations of "and" and "or". Among them, each atomic indicator contains the field data, calculation conditions, and range values of the detailed table. The field is selected through the drop-down box. The calculation conditions include 12 types: empty, not empty, contain, not contain, belong to, do not belong to, equal to, not equal to, greater than, greater than or equal to, less than, and less than or equal to. The range value is input by the user. After the logical calculation configuration of each group is completed, it can be combined into a complex nested structure, such as Figure 5 As shown, the condition can be set for field 1 to be not empty, the condition can be set for field 2 to contain (1, 2, 3), the condition can be set for field 3 to be equal to "a1", and the conditions can be combined and calculated by logical conditions for field 1, field 2, and field 3.
[0086] When the data input box and the indicator list are configured, the first SQL syntax tree can be constructed according to the atomic expression, general restriction conditions, time restriction conditions, and statistical dimensions, and then SQL instructions can be automatically generated according to the first SQL syntax tree.
[0087] Specifically, in some embodiments, constructing the first SQL syntax tree according to the atomic expression, the general limiting condition, the time limiting condition, and the statistical dimension includes:
[0088] Construct an initial SQL syntax tree; the initial SQL syntax tree includes the SELECT clause, FROM clause, WHERE clause, and GROUP-BY clause;
[0089] Add statistical dimensions to the GROUP-BY clause;
[0090] Add a time qualification to the WHERE clause;
[0091] According to the general limiting conditions, several WHERE clauses are spliced according to the logical relationship; the general limiting conditions include two logical calculations: AND and OR;
[0092] Add atomic expressions and statistical dimensions to the SELECT clause;
[0093] The GROUP-BY clause, the WHERE clause, and the SELECT clause are combined to obtain a first SQL syntax tree.
[0094] The initial SQL syntax tree includes four fields: SELECT, FROM, WHERE, and GROUP-BY. The first SQL syntax tree can be obtained by completing the four fields. For example, in order to obtain the daily iron production rate in 2023, the business personnel first select the blast furnace iron production from the production details table on the second operation interface, select the time dimension data from the process parameter table, and add the time range restriction condition, for example: date 2023-01-01 to 2023-12-31, then the first SQL syntax tree is:
[0095] SELECT date, SUM(blast furnace iron output) / COUNT(DISTINCT blast furnace ID) AS daily iron output rate;
[0096] FROM production list;
[0097] WHERE date BETWEEN '2023-01-01' AND '2023-12-31';
[0098] GROUP-BY date;
[0099] In order to further optimize the first SQL syntax tree, more limiting conditions may be added. For example, limiting conditions may be added to the blast furnace iron output so that the blast furnace iron output is not a null value.
[0100] In some embodiments, if the operation interface is the third operation interface, receiving an input instruction input by a user based on the data input box and the indicator list, and generating an SQL instruction includes:
[0101] Get the statistical dimensions in the data input box;
[0102] Acquire a third operation of the user based on the indicator list, and select a plurality of first SQL syntax trees from the indicator list according to the third operation;
[0103] Constructing a second SQL syntax tree according to the first SQL syntax tree and the statistical dimension;
[0104] Generate an SQL instruction according to the second SQL syntax tree.
[0105] like Figure 6 As shown, Figure 6The third operation interface is a schematic diagram; in the third operation interface, business personnel can select statistical dimensions through the indicator list. After determining the statistical dimension, all derived indicators that meet the dimension will be displayed for users to select. Users can select multiple derived indicators, and then construct the generation logic of composite indicators by selecting calculation methods and expressions.
[0106] When the expression configuration of the composite indicator is completed, the SQL instruction of the composite indicator is generated according to the given calculation logic. On the premise that multiple existing derived indicator calculation SQLs have been generated, that is, on the premise that the first SQL syntax trees corresponding to multiple derived indicators have been generated, the composite indicator only needs to replace the calculation logic of the derived indicator according to the given calculation expression to generate the second SQL syntax tree.
[0107] Specifically, constructing the second SQL syntax tree according to the first SQL syntax tree and the statistical dimension includes:
[0108] According to the statistical dimension, the first SQL syntax tree is subjected to JOIN calculation to obtain a FROM clause;
[0109] The FROM clause is mapped to output fields of the SELECT clause to obtain a second SQL syntax tree.
[0110] Among them, the JOIN calculation of multiple derived indicators according to the statistical dimension needs to supplement the two JOIN clauses in sequence, add the JOIN conditions according to the statistical dimension, and use the whole as the FROM clause. Then, map the expression mapping and the statistical dimension as the output field of SELECT to build a complete second SQL syntax tree. After the second SQL syntax tree is built, all page configuration information can be converted into a calculation SQL statement to obtain the calculation logic of the composite indicator.
[0111] Specifically, the second SQL syntax tree adds a JOIN field on the basis of the first SQL syntax tree, and the second SQL syntax tree includes five fields: SELECT, FROM, WHERE, GROUP-BY, and JOIN; The five fields are completed to obtain the second SQL syntax tree. Since the second SQL syntax tree is connected by JION on the basis of multiple first syntax trees, the JOIN field is completed. For example, after obtaining the first SQL syntax tree of the daily iron production rate in 2023, on the original basis, the blast furnace type and location information in the blast furnace information table are added to the first SQL syntax tree through the JOIN operation, wherein the blast furnace type and location information of the blast furnace information table and the daily iron production rate can be based on the statistical dimension of the blast furnace ID at the same time, and the second SQL syntax tree obtained is:
[0112] SELECT p.date, SUM(p.blast furnace iron output) / COUNT(DISTINCT p.blast furnace ID) AS daily iron output rate, h.blast furnace type, h.location;
[0113] FROM p.Production list;
[0114] JOIN h. blast furnace information table ON p. blast furnace ID = h. blast furnace ID;
[0115] WHERE p.date BETWEEN '2023-01-01' AND '2023-12-31';
[0116] GROUP-BY p. Date. h. Type of blast furnace, h. Location;
[0117] Among them, p represents the data obtained from the production details table, h represents the information obtained from the blast furnace information table, and the production details table and the blast furnace information table are connected together through the statistical dimension blast furnace ID. When three tables are associated together, the same field data in the three tables needs to be used as the statistical dimension to associate the three tables.
[0118] By querying the daily iron rate for each date, and also including the type and location information of each blast furnace, the data of multiple tables can be combined to form a more complex composite indicator.
[0119] S300: Based on the SQL instruction, call the preset configuration data to generate target data;
[0120] The target data is the result obtained and calculated from several data tables based on SQL instructions.
[0121] Specifically, in some embodiments, based on the SQL instruction, calling the preset configuration data and generating the target data includes:
[0122] Get the operation type keyword in the SQL command;
[0123] According to the operation type keyword, determine the target data table in the preset configuration data; the target data table includes a detail table and a dimension table corresponding to the operation type keyword;
[0124] Operate the target data table according to SQL instructions to obtain the target data.
[0125] First, you need to extract the operation type keyword from the SQL instruction, then match the operation type keyword through a regular expression, determine the name of the table to be operated by looking up the preset configuration data, and finally obtain the target data by executing an SQL query.
[0126] For example, the SQL command generated when obtaining the iron removal amount of a blast furnace is:
[0127] SELECT SUM(high_furnace_iron_output)AS total_high;
[0128] FROM production_details;
[0129] Among them, SUM is the operation keyword, production_details is the name of the table to be operated. After obtaining the operation keyword and the table to be operated, you can query the high_furnace_iron_output field in the production_details table, perform a sum operation, and finally obtain the target data.
[0130] In an embodiment of the present application, during the code-free processing of steel industry data, it is also necessary to configure several detail tables, summary tables and dimension tables. The detail tables store the original detail data used to calculate the indicators; for example, production detail tables, blast furnace information tables, etc. The summary table stores the indicator data that will be needed for the calculation results later; for example, the summary table stores the SQL instructions obtained by the atomic indicators and the first SQL syntax tree obtained by the derived indicators. The dimension table contains the dimension data used in the indicator calculation process, and several detail tables can be linked together through the dimension data.
[0131] S400: Displaying target data in the data output box.
[0132] After obtaining the target data, the target data can be displayed in an output box in any one of the first operation interface, the second operation interface and the third operation interface for direct observation by the user. The output box can output not only the target data but also SQL instructions.
[0133] In some embodiments, Figure 7 As shown, the embodiment of the present application provides a system for processing data without code in the steel industry, which is applied to the method for processing data without code in the steel industry provided in the above embodiment, including:
[0134] Display module and data processing module;
[0135] The data processing module is used to generate an operation interface corresponding to the indicator type according to the indicator type when receiving a selection instruction for selecting the indicator type; the operation page includes a number of data input boxes, an indicator list and a data output box;
[0136] Receive input instructions from users based on the data input box and indicator list, and generate SQL instructions;
[0137] Based on SQL instructions, call preset configuration data to generate target data;
[0138] The display module is used to: display target data in the data output box.
[0139] It can be seen from the above technical solutions that the present application provides a method and system for code-free data processing in the steel industry, the method comprising: in response to a selection instruction for selecting an indicator type, generating an operation interface corresponding to the indicator type according to the indicator type; the operation page comprises a number of data input boxes, an indicator list and a data output box; receiving input instructions input by the user based on the data input box and the indicator list, generating SQL instructions; based on the SQL instructions, calling preset configuration data, generating target data; and displaying the target data in the data output box. By inputting the required instructions in the input box and the indicator list of the operation page, the corresponding SQL instructions can be automatically generated, that is, the calculation and generation of complex indicators can be completed through simple page operations, so as to solve the problem that it is difficult to manually write SQL statements for data management.
[0140] Similar parts between the embodiments provided in this application can be referenced to each other. The specific implementation methods provided above are only a few examples under the general concept of this application and do not constitute a limitation on the protection scope of this application. For those skilled in the art, any other implementation methods expanded based on the scheme of this application without creative work belong to the protection scope of this application.
Claims
1. A method for processing data without code in the steel industry, characterized in that: include: In response to a selection instruction for selecting an indicator type, an operation interface corresponding to the indicator type is generated according to the indicator type; the operation interface includes a plurality of data input boxes, an indicator list and a data output box; Receiving an input instruction input by a user based on the data input box and the indicator list, and generating an SQL instruction; Based on the SQL instruction, calling preset configuration data to generate target data; The target data is displayed in the data output frame.
2. The method for processing data without code in the steel industry according to claim 1, characterized in that: The indicator types include atomic indicators, derived indicators and composite indicators; The operation interface includes a first operation interface corresponding to the atomic indicator, a second operation interface corresponding to the derived indicator, and a third operation interface corresponding to the composite indicator.
3. The method for processing data without code in the steel industry according to claim 2, characterized in that: If the operation interface is the first operation interface, receiving an input instruction input by a user based on the data input box and the indicator list, and generating an SQL instruction includes: Obtaining field data in the data input box; Acquire a first operation of a user based on the indicator list, and select a detailed table and a calculation function from the indicator list according to the first operation; the field data is a field of data in the detailed table; Obtaining an atomic expression according to the field data, the detail table and the calculation function; The SQL instruction is generated according to the atomic expression.
4. The method for processing data without code in the steel industry according to claim 3 is characterized in that: If the operation interface is the second operation interface, receiving an input instruction input by a user based on the data input box and the indicator list, and generating an SQL instruction includes: Obtaining the atomic expression in the data input box; Acquire a second operation of the user based on the indicator list, and select a general limiting condition, a time limiting condition, and a statistical dimension from the indicator list according to the second operation; the statistical dimension is the dimension data stored in the dimension table; Constructing a first SQL syntax tree according to the atomic expression, the general limiting condition, the time limiting condition, and the statistical dimension; The SQL instruction is generated according to the first SQL syntax tree.
5. The method for processing data without code in the steel industry according to claim 4 is characterized in that: Constructing a first SQL syntax tree according to the atomic expression, the general limiting condition, the time limiting condition, and the statistical dimension includes: Constructing an initial SQL syntax tree; the initial SQL syntax tree includes a SELECT clause, a FROM clause, a WHERE clause, and a GROUP-BY clause; Add the statistical dimension to the GROUP-BY clause; Adding the time qualification condition to the WHERE clause; According to the general limiting condition, a plurality of the WHERE clauses are spliced according to a logical relationship; the general limiting condition includes two logical calculations of AND and OR; Adding the atomic expression and the statistical dimension to a SELECT clause; The GROUP-BY clause, the WHERE clause, and the SELECT clause are combined to obtain a first SQL syntax tree.
6. The method for processing data without code in the steel industry according to claim 5, characterized in that: If the operation interface is the third operation interface, receiving an input instruction input by a user based on the data input box and the indicator list, and generating an SQL instruction includes: Obtain the statistical dimension in the data input box; Acquire a third operation of the user based on the indicator list, and select a plurality of the first SQL syntax trees from the indicator list according to the third operation; Constructing a second SQL syntax tree according to the first SQL syntax tree and the statistical dimension; The SQL instruction is generated according to the second SQL syntax tree.
7. The method for processing data without code in the steel industry according to claim 6, characterized in that: Constructing a second SQL syntax tree according to the first SQL syntax tree and the statistical dimension includes: According to the statistical dimension, performing a JOIN calculation on the first SQL syntax tree to obtain a FROM clause; The FROM clause is mapped to output fields of the SELECT clause to obtain a second SQL syntax tree.
8. The method for processing data without code in the steel industry according to claim 4, characterized in that: Based on the SQL instruction, calling the preset configuration data and generating the target data include: Obtaining the operation type keyword in the SQL instruction; According to the operation type keyword, determining a target data table in the preset configuration data; the target data table includes a detail table and a dimension table corresponding to the operation type keyword; The target data table is operated according to the SQL instruction to obtain target data.
9. A system for processing data without code in the steel industry, applied to the method for processing data without code in the steel industry as claimed in any one of claims 1 to 8, characterized in that: include: Display module and data processing module; The data processing module is used to generate an operation interface corresponding to the indicator type according to the indicator type when receiving a selection instruction for selecting an indicator type; the operation page includes a plurality of data input boxes, an indicator list and a data output box; Receiving an input instruction input by a user based on the data input box and the indicator list, and generating an SQL instruction; Based on the SQL instruction, calling preset configuration data to generate target data; The display module is used to display the target data in the data output frame.