CN-115840784-B - Data processing method, device, electronic equipment and storage medium
Abstract
The invention provides a data processing method, a data processing device, electronic equipment and a storage medium. The data processing method comprises the steps of matching an analysis algorithm from a preset analysis algorithm library based on a database address, establishing connection with the database address based on configuration information and the analysis algorithm, carrying out synchronous processing on data in a database corresponding to the database address based on a synchronous algorithm to obtain synchronous data, and if the synchronous data does not accord with a data standard, re-matching the analysis algorithm from the preset analysis algorithm library until the synchronous data accords with the data standard, and storing the synchronous data which accords with the data standard. The data processing method of the embodiment of the invention improves the reliability of grain condition data processing.
Inventors
- ZHANG DELONG
- LI CHAO
- YAN TONG
Assignees
- 航天信息股份有限公司
Dates
- Publication Date
- 20260508
- Application Date
- 20221226
Claims (8)
- 1. A data processing method, comprising: based on the database address, matching an analysis algorithm from a preset analysis algorithm library; Establishing connection with the database address based on configuration information and the analysis algorithm; carrying out synchronous processing on data in a database corresponding to the database address based on a synchronous algorithm to obtain synchronous data; Performing text feature analysis processing on the synchronous data to generate an analysis result, and judging whether the synchronous data accords with a data standard according to the analysis result, wherein if the analysis result indicates that the text feature of the synchronous data is abnormal, the synchronous data does not accord with the data standard; If the synchronous data does not accord with the data standard, re-matching an analysis algorithm from the preset analysis algorithm library until the synchronous data accords with the data standard; storing synchronous data conforming to the data standard; The method comprises the steps of analyzing the database address through the analysis algorithm to obtain an analysis result, configuring a connection interface according to the configuration information, and establishing connection with the database address through the connection interface and the analysis result.
- 2. The method of claim 1, wherein said establishing a connection with said database address via said connection interface and said parsing result comprises: Judging whether the connection with the database address is successful or not; If the connection with the database address fails, the database address is analyzed by a re-matching analysis algorithm from the preset analysis algorithm library until the connection with the database address is successful.
- 3. The method of claim 1 or 2, further comprising: the synchronous data does not accord with the data standard or fails to connect with the database address, and the analysis algorithm fails to analyze the database address; If all the analysis algorithms in the preset analysis algorithm library fail to analyze the database address, expanding a new analysis algorithm through an expansion plug-in, and analyzing the database address through the new analysis algorithm until the database address analysis is successful.
- 4. The method of claim 1, wherein storing the synchronization data that meets the data standard comprises: Establishing a class label for the synchronous data according to the data type; and storing the synchronous data into a corresponding tag database according to the category tag.
- 5. The method as recited in claim 1, further comprising: matching the configuration information from a preset configuration information base according to the database address; Carrying out information configuration on the database address and the connection interface through the configuration information; and if the configuration information fails to configure the database address and the connection interface, the configuration information is re-matched to perform information configuration on the database address and the connection interface until the configuration is successful.
- 6. A data processing apparatus comprising: the connection module is used for matching an analysis algorithm from a preset analysis algorithm library based on a database address, and establishing connection with the database address based on configuration information and the analysis algorithm; The processing module is used for carrying out synchronous processing on data in a database corresponding to the database address based on a synchronous algorithm to obtain synchronous data, carrying out text feature analysis processing on the synchronous data to generate an analysis result, and judging whether the synchronous data accords with a data standard according to the analysis result, wherein if the analysis result indicates that the text feature of the synchronous data is abnormal, the synchronous data does not accord with the data standard, and if the synchronous data does not accord with the data standard, the synchronous data is re-matched with an analysis algorithm from the preset analysis algorithm library until the synchronous data accords with the data standard; the storage module is used for storing the synchronous data which accords with the data standard; The connection module is also used for resolving the database address through the resolving algorithm to obtain resolving results, configuring a connection interface according to the configuration information, and establishing connection with the database address through the connection interface and the resolving results.
- 7. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the steps of the data processing method according to any one of claims 1 to 5 when the computer program is executed.
- 8. A computer storage medium, characterized in that it has stored thereon a computer program which, when executed by a processor, implements the steps of the data processing method according to any of claims 1 to 5.
Description
Data processing method, device, electronic equipment and storage medium Technical Field The embodiment of the invention relates to the technical field of computers, in particular to a data processing method, a data processing device, electronic equipment and a storage medium. Background Along with popularization and application of grain informatization, grain varieties required to be collected are more and more when grain conditions are collected, and each grain variety corresponds to different manufacturers, so that difficulty is brought to unification of the grain conditions, and the data extraction of each manufacturer is faced to the first step of unification. In the prior art, the data of each manufacturer is extracted manually, and because the database addresses, the data types and the like of each manufacturer have differences, different algorithms are needed to be selected to analyze the data addresses of each manufacturer, and the algorithms are usually selected manually, but the situation that the algorithms are not matched easily occurs when the algorithms are selected manually, the speed of manually extracting the data is low, and the extracted data is easy to be wrong. Therefore, the reliability of the grain condition data processing method is poor. Disclosure of Invention In view of the above, embodiments of the present invention provide a data processing method and apparatus, an electronic device, and a storage medium, so as to solve the above problems. According to a first aspect of the embodiment of the invention, a data processing method is provided, which comprises the steps of matching an analysis algorithm from a preset analysis algorithm library based on a database address, establishing connection with the database address based on configuration information and the analysis algorithm, carrying out synchronous processing on data in a database corresponding to the database address based on a synchronous algorithm to obtain synchronous data, re-matching the analysis algorithm from the preset analysis algorithm library until the synchronous data accords with a data standard if the synchronous data does not accord with the data standard, and storing the synchronous data which accords with the data standard. In another implementation mode of the invention, connection is established with the database address based on the configuration information and the analysis algorithm, and the method comprises the steps of analyzing the database address through the analysis algorithm to obtain an analysis result, configuring a connection interface according to the configuration information, and establishing connection with the database address through the connection interface and the analysis result. In another implementation mode of the invention, the connection is established with the database address through the connection interface and the analysis result, and the method comprises the steps of judging whether the connection with the database address is successful or not, and if the connection with the database address is failed, carrying out analysis on the database address by a re-matching analysis algorithm from a preset analysis algorithm library until the connection with the database address is successful. In another implementation mode of the invention, the data processing method further comprises the steps that synchronous data does not accord with data standards or fails to be connected with the address of the analysis database, the analysis algorithm fails to analyze the address of the database, if the analysis algorithms in the analysis algorithm library fail to analyze the address of the database, a new analysis algorithm is expanded through an expansion plug-in, and analysis processing is carried out on the address of the database through the new analysis algorithm until the analysis of the address of the database is successful. In another implementation mode of the invention, judging whether the synchronous data accords with the data standard comprises the steps of carrying out text feature analysis processing on the synchronous data to generate an analysis result, judging whether the synchronous data accords with the data standard according to the analysis result, and if the analysis result indicates that the text feature of the synchronous data is abnormal, judging that the synchronous data does not accord with the data standard. In another implementation mode of the invention, storing the synchronous data meeting the data standard comprises establishing a class label for the synchronous data according to the data type and storing the synchronous data into a corresponding label database according to the class label. In another implementation mode of the invention, the data processing method further comprises the steps of matching configuration information from a preset configuration information base according to the database address, carrying out information configuration on the databas