Character string type data processing method and device, equipment and medium
By building standardized data cleaning rules and integrating them into the software development kit, the problem of low efficiency in string data processing in the data warehouse was solved, unified cleaning and encrypted storage were achieved, and the construction efficiency and security of the data warehouse were improved.
Patent Information
- Application Number
- CN202510733420.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-30
- Publication Date
- 2025-09-12
AI Technical Summary
When building a data warehouse, existing technologies have low data processing efficiency, especially due to the heterogeneity of string data, and existing methods may lead to data loss or management confusion.
By obtaining the initial string data of multiple business scenarios, we build standardized data cleaning rules and integrate them into the software development kit. We call the data cleaning rules in the software development kit to perform data cleaning processing, generate encrypted data and store it in the target data warehouse.
It implements unified cleaning rules for data warehouses, improves the efficiency of data warehouse construction, and ensures the security and integrity of data.
Smart Images

Figure CN120632167A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of data processing technology and is applicable to financial and medical scenarios. In particular, it relates to a method, device, equipment and medium for processing string data. Background Art
[0002] During the construction and operation of data warehouses, data integration across multiple business systems faces significant challenges. Different business systems employ widely varying validation rules and storage strategies during data entry, resulting in significant heterogeneity in the data once it enters the warehouse. In particular, string data comes in a variety of formats, such as international standard formats, redundant symbol formats, and abbreviation formats. This heterogeneity increases the complexity of data cleansing and affects the accuracy of subsequent data processing and analysis. This is particularly prominent in fields such as finance and healthcare. For example, in financial scenarios, inconsistent formats for fields such as customer information and transaction descriptions can impact risk control and anti-fraud models. In healthcare, the unstructured nature of data such as medical records and diagnostic information can hinder clinical decision-making and cross-institutional data sharing.
[0003] In order to cope with the diversity of string data formats, the existing technology can directly encrypt and store the original data. Although this sampling method avoids data loss, it requires repeated decryption and cleaning during analysis. Non-standard data can also be filtered through fixed rules. Although this method improves data quality, it may cause the loss of key information. In addition, encryption can be used during data transmission, and data from different business systems can be connected to the data warehouse. When analyzing string data in different formats, regular expressions are used for cleaning and then correlation analysis. Although this method achieves local standardization, the dispersion of regular expression rules leads to chaotic data warehouse management.
[0004] In view of this, how to effectively improve the processing capabilities of string data while ensuring data security and integrity, and thereby improve the efficiency of data warehouse construction, is a technical problem that needs to be solved urgently. Summary of the Invention
[0005] The present invention provides a method, device, equipment and medium for processing string type data to solve the technical problem of low construction efficiency of existing data warehouses.
[0006] In a first aspect, the present invention provides a method for processing string data, comprising:
[0007] Obtaining initial string data for multiple business scenarios, and building corresponding standardized data cleaning rules based on the initial string data;
[0008] Integrating the standardized data cleaning rules into a software development kit, and calling the software development kit to perform data cleaning processing on the initial character string data to obtain standardized target character string data;
[0009] The target character string data is encrypted by an encryption algorithm to generate ciphertext data corresponding to the target character string data, and the ciphertext data is stored in a target data warehouse.
[0010] In a second aspect, the present invention provides a device for processing string data, comprising:
[0011] A construction module is used to obtain initial string data of multiple business scenarios and construct corresponding standardized data cleaning rules based on the initial string data;
[0012] A processing module, configured to integrate the standardized data cleaning rules into a software development kit, and call the software development kit to perform data cleaning on the initial character string data to obtain standardized target character string data;
[0013] The storage module is used to encrypt the target string type data through an encryption algorithm, generate ciphertext data corresponding to the target string type data, and store the ciphertext data in a target data warehouse.
[0014] In a third aspect, the present invention provides a computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the above-mentioned method for processing string data when executing the computer program.
[0015] In a fourth aspect, the present invention provides a computer-readable storage medium storing a computer program, which implements the steps of the above-mentioned method for processing string data when executed by a processor.
[0016] In the above-mentioned string type data processing method, device, equipment and medium, in the implemented scheme, the initial string type data of multiple business scenarios can be obtained through the client, and corresponding standardized data cleaning rules can be constructed based on the initial string type data; the standardized data cleaning rules are integrated into the software development kit, and the software development kit is called to perform data cleaning processing on the initial string type data to obtain standardized target string type data; the target string type data is encrypted by an encryption algorithm to generate ciphertext data corresponding to the target string type data, and the ciphertext data is stored in the target data warehouse. In the present invention, when processing string type data, the standardized data cleaning rules can be integrated into the software development kit. It only needs to call the data cleaning rules in the software development kit to perform data cleaning processing on the initial string type data, so that the entire data warehouse maintains a unified cleaning rule, and data cleaning is performed during the data integration process, and is directly referenced in subsequent calls and storage processes without repeated cleaning, which effectively improves the construction efficiency of the data warehouse. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments of the present invention. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0018] Figure 1 This is a schematic diagram of an application environment of a method for processing string data according to an embodiment of the present invention;
[0019] Figure 2 1 is a flow chart of a method for processing string data according to an embodiment of the present invention;
[0020] Figure 3 yes Figure 2 A schematic flow chart of a specific implementation of step S10;
[0021] Figure 4 yes Figure 2 A schematic flow chart of a specific implementation of step S20;
[0022] Figure 5 is a schematic structural diagram of a device for processing string data in one embodiment of the present invention;
[0023] Figure 6 is a structural diagram of a computer device in one embodiment of the present invention;
[0024] Figure 7FIG. 2 is another structural diagram of a computer device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0025] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of them. All other embodiments obtained by ordinary technicians in this field based on the embodiments of the present invention without making any creative efforts shall fall within the scope of protection of the present invention.
[0026] The method for processing string data provided by the embodiment of the present invention can be applied in the following situations: Figure 1 In the application environment, Figure 1 The present invention is a schematic diagram of an application environment of a method for processing string data in an embodiment of the present invention; wherein, a client communicates with a server via a network. The server can obtain initial string data of multiple business scenarios through the client, and construct corresponding standardized data cleaning rules based on the initial string data; integrate the standardized data cleaning rules into a software development kit, and call the software development kit to perform data cleaning on the initial string data to obtain standardized target string data; encrypt the target string data using an encryption algorithm to generate ciphertext data corresponding to the target string data, and store the ciphertext data in a target data warehouse. In the present invention, when processing string data, the standardized data cleaning rules can be integrated into the software development kit. Only the data cleaning rules in the software development kit need to be called to perform data cleaning on the initial string data, so that the entire data warehouse maintains a unified cleaning rule, and data cleaning is performed during the data integration process. It can be directly referenced in subsequent calls and storage processes without repeated cleaning, effectively improving the efficiency of data warehouse construction. The present invention is described in detail below through specific embodiments.
[0027] See also Figure 2 As shown, Figure 2 A flowchart of a method for processing string data provided by an embodiment of the present invention is provided. The method for processing string data specifically includes the following steps:
[0028] S10: Obtain the initial string type data of multiple business scenarios, and construct corresponding standardized data cleaning rules based on the initial string type data. Specifically, in an embodiment of the present invention, the initial string type data of multiple business scenarios can be obtained first, and corresponding standardized cleaning rules can be set according to the obtained initial string type data. By setting corresponding data cleaning rules for different business scenarios, unified formatting and standardization of string type data can be achieved, avoiding errors and inconsistencies caused by confusion in the format of string type data. Specifically, Figure 3 As stated, Figure 3 This is a flow chart of a specific implementation of step S10, which specifically includes the following steps S11-S13:
[0029] S11: The format of the initial string type data is standardized by using a predefined regular expression, and the valid fields of the initial string type data after the format standardization are extracted. Specifically, in an embodiment of the present invention, by using a predefined regular expression to standardize the format of the initial string type data, the storage confusion caused by inconsistent formats of different data sources can be eliminated. Through the data after format standardization, useful fields can be effectively extracted to avoid irrelevant information interfering with subsequent data analysis. For example, in a financial scenario, the account number may be in a mixed format of numbers, letters, or pure numbers. These account numbers in different formats can be standardized through regular expressions to make them conform to a unified format. In the medical industry, data sources such as medical records and diagnostic records are complex and in different formats. Through the standardization processing of regular expressions, the patient name, diagnosis code, consultation date, etc. in the medical record can be extracted into a consistent format, which is convenient for subsequent storage and analysis.
[0030] S12: Verify the valid fields of the extracted initial string type data after the format standardization processing. Specifically, in an embodiment of the present invention, by verifying the valid fields of the initial string type data, potential erroneous data such as format errors, missing fields, invalid values, etc. can be captured. For example, in the financial industry, fields such as the customer's transaction amount and transaction date must conform to a certain format. Through verification processing, it can be ensured that the data complies with the predetermined rules. If the verification fails, the problem can be discovered and corrected in time to ensure the accuracy and compliance of the financial data. In medical scenarios, the patient's medical records, diagnosis results, etc. must comply with the specifications of the medical industry. Verification can ensure the accuracy of fields such as diagnosis codes and patient information.
[0031] S13: Based on the verification results of the valid fields of the initial string type data, a cleaning rule template that matches each business scenario is generated. In an embodiment of the present invention, cleaning rules can be customized according to different business needs, providing a standardized and reusable framework for subsequent data processing. For example, in the financial industry, during the credit review process, it is necessary to verify the borrower's identity, income and other information, and ensure format consistency. In the medical industry, different business scenarios require different data cleaning rules. When entering medical records, the main focus is on the accuracy and completeness of patient information; in clinical decision support systems, it is necessary to generate cleaning rule templates based on diagnostic records and laboratory results. Specifically including the following steps S131-S132:
[0032] S131: Obtain a scenario identifier for each business scenario and match a basic cleaning rule template corresponding to the business scenario from a preset cleaning rule library. Specifically, in embodiments of the present invention, the scenario identifier can be used to quickly match the preset cleaning rule template, improving deployment efficiency. Matching the basic cleaning rule template corresponding to the business scenario from the preset cleaning rule library increases the reusability of cleaning rules and avoids duplicate development.
[0033] S132: Based on the conflicting data in the verification results of the valid fields of the initial string data, corresponding correction rules are added to the basic cleansing rule templates corresponding to the business scenarios, thereby generating cleansing rule templates that match the business scenarios. Specifically, in this embodiment of the present invention, although the basic cleansing templates are universal, conflicts often exist in actual data. Correction rules can be automatically added to address the conflicting data, making the cleansing templates more suitable for actual scenarios.
[0034] S20: Integrate the standardized data cleaning rules into the software development kit, and call the software development kit to perform data cleaning on the initial string type data to obtain standardized target string type data. Specifically, in the embodiment of the present invention, after constructing the corresponding standardized data cleaning rules based on the initial string type data in step S10, it is also necessary to integrate the cleaning rules into the software development kit, and then call the cleaning rules in the software development kit to perform cleaning, which can reduce manual intervention and improve the efficiency of data cleaning. Specifically, as Figure 4 As stated, Figure 4 This is a flow chart of a specific implementation of step S20, which specifically includes the following steps S21-S23:
[0035] S21: Decomposing the standardized data cleaning rules according to different functional modules, and encapsulating the standardized data cleaning rules of each decomposed functional module into independent function modules. Specifically, in an embodiment of the present invention, the cleaning rules can be decomposed into different functional modules, so that each module only processes a specific task. This modular design enhances the maintainability, scalability, and reusability of the code. Each functional module can be independently developed, debugged, tested, and optimized, reducing the impact of a single module failure.
[0036] S22: Compile and package each independent function module with the corresponding dependent library to generate a software development kit. Specifically, in an embodiment of the present invention, by packaging each independent module and its dependent library into a software development kit, the packaged software development kit contains all dependencies, which can ensure that the software can run smoothly on different platforms. For example, in a financial scenario, in a banking system, after packaging the data cleaning module and the dependent library into a software development kit, the bank can uniformly deploy the software development kit to business scenarios such as the credit system, risk control system, and account system. In a medical scenario, the packaged software development kit can be directly called by the hospital's outpatient system, inpatient management system, medical insurance settlement system and other subsystems. When the hospital needs to adjust the data cleaning rules or optimize certain functions, it only needs to update the version of the software development kit and it can be used directly, effectively reducing maintenance costs.
[0037] S23: By calling the standardized data cleaning rules of each independent function module in the software development kit, the initial string type data is cleaned and processed to obtain standardized target string type data. Specifically, in an embodiment of the present invention, by calling the cleaning module in the software development kit, format verification, missing value filling, abnormal data repair and other operations can be performed according to standard rules, reducing the need for manual intervention and improving work efficiency. For example, in a financial scenario, the loan application information submitted by the customer usually needs to be formatted, verified and cleaned. By calling the data cleaning module in the software development kit, the personal information submitted by the customer can be automatically cleaned. For example, income fields in different formats can be unified into an annual income format, and data processing and approval decisions can be completed in a short time. In a medical scenario, when a patient submits or a doctor enters data, the software development kit is called to clean the data to ensure that the input data of each department is consistent. Specifically including the following steps S231-S233:
[0038] S231: Call the format processing function module in the software development kit to perform format standardization processing on the initial string type data to obtain string type data after format standardization processing. Specifically, in an embodiment of the present invention, format standardization processing can unify data of different formats into a standard format to ensure the uniformity of the data. For example, date format, telephone number format, etc., after standardization processing, all data adopt the same format, which is convenient for subsequent processing, storage and analysis. For example, in a financial scenario, if the telephone formats submitted by different customers are different, the standardization module will convert all telephone numbers into a unified format. In a medical scenario, there may be format inconsistencies in fields such as the patient's admission date and hospitalization number. Through formatting processing, these date fields will be standardized into a unified format to ensure that all data formats in the hospital information system are consistent.
[0039] S232: Call the validity check function module in the software development kit to perform validity check on the string data after format standardization, and obtain the string data after validity check. Specifically, in an embodiment of the present invention, the verification function module can ensure the correctness of the input data and prevent erroneous data from affecting subsequent processes. For example, in a financial scenario, when a customer submits personal information, a validity check will be performed, such as checking whether the mobile phone number complies with the format specified by the state. In a medical scenario, it is checked whether the date of birth entered by the patient is within a reasonable range.
[0040] S233: Call the business rule matching module in the software development kit to perform business rule matching processing on the string type data after validity verification to obtain standardized target string type data. Specifically, in an embodiment of the present invention, the business rule matching module can perform higher-level matching and processing on the data according to the specific business scenario, ensuring that the data not only meets the format and validity requirements, but also meets the industry-specific business specifications. For example, in a financial scenario, through the business rule matching module, the system can match the basic information of the customer with the corresponding credit assessment standards, loan approval conditions and other business scenarios to generate customer data that ultimately meets the loan requirements. In a hospital management system, a patient's treatment plan or drug prescription may be judged based on a variety of business rules. For example, information such as the patient's age, weight, and severity of illness can be matched with the rules set by the doctor to generate a personalized treatment plan.
[0041] S30: Encrypt the target string data using an encryption algorithm to generate ciphertext data corresponding to the target string data, and store the ciphertext data in the target data warehouse. In this embodiment of the present invention, encrypting the cleaned data using an encryption algorithm can ensure the security of the data during storage and transmission. Specifically, the following steps are included: S31:
[0042] S31: Encrypt the standardized string data using a hash algorithm to generate ciphertext data corresponding to the standardized string data, and store the ciphertext data in the target data warehouse. In an embodiment of the present invention, encrypting the standardized string data using a hash algorithm can effectively prevent sensitive information from being leaked or illegally tampered with. The hash encryption algorithm is irreversible, and even if the data is obtained, it cannot be restored to the original content, thereby improving the security of the data during storage and transmission. Specifically, it includes the following steps S311-S312:
[0043] S311: Perform a hash operation on the standardized string type data to generate hash value ciphertext data corresponding to the standardized string type data. Specifically, in an embodiment of the present invention, the standardized string type data is converted into a hash value through a hash algorithm to avoid storing data in plain text and reduce the risk of sensitive data leakage. For example, in a financial scenario, financial institutions need to store a large amount of personal information of customers, which are all sensitive data. By performing a hash operation on the standardized string type data, a hash value can be generated and stored. In a medical scenario, when a patient's medical data needs to be shared between multiple hospitals, the hash value can be exchanged as a de-identified tag to ensure data privacy protection.
[0044] S312: Verify the integrity of the standardized string data. If the integrity check of the standardized string data passes, the generated hash value ciphertext data corresponding to the standardized string data is stored in the target data warehouse. Specifically, in an embodiment of the present invention, a hash algorithm generates a unique hash value for each data. By comparing two hash values, data consistency can be quickly verified, helping to ensure the integrity and accuracy of the data during transmission or storage. If the data integrity check fails, an alarm mechanism can be triggered or the data can be retransmitted, avoiding the storage of erroneous or tampered data. If the integrity check of the standardized string data passes, the generated hash value ciphertext data corresponding to the standardized string data is stored in the target data warehouse. For example, in a bank's loan system, credit application information needs to be standardized and hashed before storage. If the original application data is tampered with during processing, this change can be detected by verifying the hash value. If the hash values are inconsistent, the data can be marked as a problematic record and further manual review or resubmission can be performed. In medical scenarios, when a patient's medical records are transmitted from one department to another, the medical record data needs to be hashed and integrity verified to ensure that the medical records have not been tampered with during transmission.
[0045] It can be seen that in the above solution, when processing string data, standardized data cleaning rules can be integrated into the software development kit. Only the data cleaning rules in the software development kit need to be called to perform data cleaning on the initial string data, so that the entire data warehouse maintains unified cleaning rules. In addition, data cleaning is performed during the data integration process, and it can be directly referenced in subsequent calls and storage processes without repeated cleaning, which effectively improves the efficiency of data warehouse construction.
[0046] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention.
[0047] In one embodiment, a device for processing string type data is provided, which corresponds to the method for processing string type data in the above embodiment. Figure 5 As shown, Figure 5 1 is a schematic diagram of a structure of a device for processing string data according to an embodiment of the present invention. The device for processing string data includes a construction module 51, a processing module 52, and a storage module 53. The functional modules are described in detail as follows:
[0048] A construction module 51 is used to obtain initial string data of multiple business scenarios and construct corresponding standardized data cleaning rules based on the initial string data;
[0049] A processing module 52 is configured to integrate the standardized data cleaning rules into a software development kit and call the software development kit to perform data cleaning on the initial character string data to obtain standardized target character string data;
[0050] The storage module 53 is used to encrypt the target character string data using an encryption algorithm, generate ciphertext data corresponding to the target character string data, and store the ciphertext data in a target data warehouse.
[0051] In one embodiment, the building module 51 is specifically configured to:
[0052] Performing format standardization processing on the initial string type data using a predefined regular expression, and extracting valid fields of the initial string type data after the format standardization processing;
[0053] Verify the valid fields of the extracted initial string data after format standardization;
[0054] Based on the verification results of the valid fields of the initial string data, a cleaning rule template that matches each business scenario is generated.
[0055] In one embodiment, the building module 51 is specifically configured to:
[0056] Obtain the scenario identifier of each business scenario and match the basic cleaning rule template corresponding to the business scenario from the preset cleaning rule library;
[0057] Based on the conflicting data in the verification result of the valid field of the initial string data, corresponding correction rules are added to the basic cleaning rule template corresponding to each business scenario to generate a cleaning rule template matching each business scenario.
[0058] In one embodiment, the processing module 52 is specifically configured to:
[0059] Decomposing the standardized data cleaning rules according to different functional modules, and encapsulating the standardized data cleaning rules of each functional module into independent function modules;
[0060] Compile and package each independent function module with the corresponding dependent library to generate a software development kit;
[0061] By calling the standardized data cleaning rules of each independent function module in the software development kit, the initial string type data is cleaned to obtain standardized target string type data.
[0062] In one embodiment, the processing module 52 is specifically configured to:
[0063] Calling the format processing function module in the software development kit to perform format standardization processing on the initial character string data to obtain the character string data after format standardization processing;
[0064] Calling the validity check function module in the software development kit to perform validity check on the string data after format standardization processing to obtain the string data after validity check;
[0065] The business rule matching module in the software development kit is called to perform business rule matching processing on the validity-verified character string data to obtain standardized target character string data.
[0066] In one embodiment, the storage module 53 is specifically configured to:
[0067] The standardized character string data is encrypted by a hash algorithm to generate ciphertext data corresponding to the standardized character string data, and the ciphertext data is stored in a target data warehouse.
[0068] In one embodiment, the storage module 53 is specifically configured to:
[0069] Performing a hash operation on the standardized character string data to generate hash value ciphertext data corresponding to the standardized character string data;
[0070] The integrity of the standardized character string data is verified. If the integrity verification of the standardized character string data passes, the generated hash value ciphertext data corresponding to the standardized character string data is stored in the target data warehouse.
[0071] The present invention provides a device for processing string data. When processing string data, standardized data cleaning rules can be integrated into a software development kit. The initial string data can be cleaned by simply calling the data cleaning rules in the software development kit, so that the entire data warehouse maintains unified cleaning rules. In addition, data cleaning is performed during the data integration process and can be directly referenced in subsequent calls and storage processes without the need for repeated cleaning, thereby effectively improving the construction efficiency of the data warehouse.
[0072] The specific definition of the string data processing device can be found in the definition of the string data processing method described above and will not be repeated here. The various modules in the string data processing device described above can be implemented in whole or in part by software, hardware, or a combination thereof. The aforementioned modules can be embedded in or independent of the processor in the computer device in hardware form, or can be stored in the memory of the computer device in software form, so that the processor can call and execute the operations corresponding to the aforementioned modules.
[0073] In one embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as follows: Figure 6 As shown, Figure 6 1 is a schematic diagram of the structure of a computer device in one embodiment of the present invention. The computer device includes a processor, a memory, a network interface, and a database connected via a system bus. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile and / or volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of the operating system and computer program in the non-volatile storage medium. The network interface of the computer device is used to communicate with an external client via a network connection. When the computer program is executed by the processor, it implements the functions or steps on the server side of a method for processing string data.
[0074] In one embodiment, a computer device is provided. The computer device may be a client, and its internal structure diagram may be as follows: Figure 7 As shown, Figure 71 is another structural schematic diagram of a computer device according to one embodiment of the present invention. The computer device includes a processor, memory, a network interface, a display screen, and an input device connected via a system bus. The processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and computer program in the non-volatile storage medium. The network interface of the computer device is configured to communicate with an external server via a network connection. When executed by the processor, the computer program implements the client-side functions or steps of a method for processing string data.
[0075] In one embodiment, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the following steps are performed:
[0076] Obtaining initial string data for multiple business scenarios, and building corresponding standardized data cleaning rules based on the initial string data;
[0077] Integrating the standardized data cleaning rules into a software development kit, and calling the software development kit to perform data cleaning processing on the initial character string data to obtain standardized target character string data;
[0078] The target character string data is encrypted by an encryption algorithm to generate ciphertext data corresponding to the target character string data, and the ciphertext data is stored in a target data warehouse.
[0079] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the following steps are implemented:
[0080] Obtaining initial string data for multiple business scenarios, and building corresponding standardized data cleaning rules based on the initial string data;
[0081] Integrating the standardized data cleaning rules into a software development kit, and calling the software development kit to perform data cleaning processing on the initial character string data to obtain standardized target character string data;
[0082] The target character string data is encrypted by an encryption algorithm to generate ciphertext data corresponding to the target character string data, and the ciphertext data is stored in a target data warehouse.
[0083] It should be noted that the above functions or steps that can be implemented by the computer-readable storage medium or computer device can be found in the relevant descriptions of the server side and the client side in the aforementioned method embodiment. To avoid repetition, they will not be described one by one here.
[0084] Those skilled in the art will appreciate that all or part of the processes in the above-mentioned embodiment methods can be implemented by instructing the relevant hardware through a computer program. The computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchl ink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
[0085] Those skilled in the art will clearly understand that for the sake of convenience and brevity of description, only the division of the above-mentioned functional units and modules is used as an example. In actual applications, the above-mentioned functions can be distributed and completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above.
[0086] The embodiments described above are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the various embodiments of the present invention, and should all be included in the scope of protection of the present invention.
Claims
1. A method for processing string data, characterized in that: include: Obtaining initial string data for multiple business scenarios, and building corresponding standardized data cleaning rules based on the initial string data; Integrating the standardized data cleaning rules into a software development kit, and calling the software development kit to perform data cleaning processing on the initial character string data to obtain standardized target character string data; The target character string data is encrypted by an encryption algorithm to generate ciphertext data corresponding to the target character string data, and the ciphertext data is stored in a target data warehouse.
2. The method for processing character string data according to claim 1, wherein: The method of obtaining initial string data of a business scenario and constructing corresponding standardized data cleaning rules based on the initial string data includes: Performing format standardization processing on the initial string type data using a predefined regular expression, and extracting valid fields of the initial string type data after the format standardization processing; Verify the valid fields of the extracted initial string data after format standardization; Based on the verification results of the valid fields of the initial string data, a cleaning rule template that matches each business scenario is generated.
3. The method for processing character string data according to claim 2, wherein: The verification result of the valid fields of the initial string data is used to generate a cleaning rule template that matches each business scenario; including: Obtain the scenario identifier of each business scenario and match the basic cleaning rule template corresponding to the business scenario from the preset cleaning rule library; Based on the conflicting data in the verification result of the valid field of the initial string data, corresponding correction rules are added to the basic cleaning rule template corresponding to each business scenario to generate a cleaning rule template matching each business scenario.
4. The method for processing character string data according to claim 1, wherein: The method of integrating the standardized data cleaning rules into a software development kit and calling the software development kit to perform data cleaning on the initial character string data to obtain standardized target character string data includes: Decomposing the standardized data cleaning rules according to different functional modules, and encapsulating the standardized data cleaning rules of each functional module into independent function modules; Compile and package each independent function module with the corresponding dependent library to generate a software development kit; By calling the standardized data cleaning rules of each independent function module in the software development kit, the initial character string data is cleaned to obtain standardized target character string data.
5. The method for processing character string data according to claim 4, wherein: The method cleans the initial string data by calling the standardized data cleaning rules of each independent function module in the software development kit to obtain standardized target string data; including: Calling the format processing function module in the software development kit to perform format standardization processing on the initial character string data to obtain the character string data after format standardization processing; Calling the validity check function module in the software development kit to perform validity check on the string data after format standardization processing to obtain the string data after validity check; The business rule matching module in the software development kit is called to perform business rule matching processing on the validity-verified character string data to obtain standardized target character string data.
6. The method for processing character string data according to claim 1, wherein: The method of encrypting the standardized character string data by using an encryption algorithm to generate ciphertext data corresponding to the standardized character string data, and storing the ciphertext data in a target data warehouse includes: The standardized character string data is encrypted by a hash algorithm to generate ciphertext data corresponding to the standardized character string data, and the ciphertext data is stored in a target data warehouse.
7. The method for processing character string data according to claim 6, wherein: The method of encrypting the standardized character string data by using a hash algorithm to generate ciphertext data corresponding to the standardized character string data, and storing the ciphertext data in a target data warehouse includes: Performing a hash operation on the standardized character string data to generate hash value ciphertext data corresponding to the standardized character string data; The integrity of the standardized character string data is verified. If the integrity verification of the standardized character string data passes, the generated hash value ciphertext data corresponding to the standardized character string data is stored in the target data warehouse.
8. A device for processing string data, the device being used to implement the method for processing string data according to any one of claims 1 to 7, characterized in that: The device comprises: A construction module is used to obtain initial string data of multiple business scenarios and construct corresponding standardized data cleaning rules based on the initial string data; A processing module, configured to integrate the standardized data cleaning rules into a software development kit, and call the software development kit to perform data cleaning on the initial character string data to obtain standardized target character string data; The storage module is used to encrypt the target string type data through an encryption algorithm, generate ciphertext data corresponding to the target string type data, and store the ciphertext data in a target data warehouse.
9. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the computer program, the steps of the method for processing character string data according to any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of the method for processing character string data according to any one of claims 1 to 7 are implemented.