A kind of SQL parser and method
A parsing method and parser technology, applied in the direction of instruments, structured data retrieval, calculation, etc., can solve the problems of limited application scope, low parsing efficiency of SQL parser, inability to modify the content of parser, etc., to improve the scope of application. Effect
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0041] The embodiment of the present invention provides a SQL parser, such as figure 1 As shown, the SQL parser includes: an input interface module 1, a SQL analysis engine 2, and an output interface module 3; the input interface module 1 is in communication connection with the SQL analysis engine 2, and the output interface module 3 is in communication connection with the SQL analysis engine 2. among them,
[0042] The input interface module 1 is used to map the received multi-type data into a data stream in a preset format according to a preset conversion rule, and send it to the SQL parsing engine 2;
[0043] The SQL parsing engine 2 is used to sequentially process the data stream in the above preset format into a character stream, a format file and an abstract syntax tree object, and send it to the output interface module 3;
[0044] The output interface module 3 is used to map the above-mentioned abstract syntax tree object into a data stream output of the required type.
[0045]...
Embodiment 2
[0056] The embodiment of the present invention provides a SQL parsing method, which is implemented based on the SQL parser described in the first embodiment, such as figure 2 As shown, the method includes:
[0057] S1. The input interface module is used to map the received multi-type data into a data stream in a preset format according to a preset conversion rule, and send it to the SQL parsing engine;
[0058] S2. The SQL parsing engine is used to sequentially process the data stream in the above preset format into a character stream, a format file and an abstract syntax tree object, and send it to the output interface module;
[0059] S3. The output interface module is used to map the abstract syntax tree object into a data stream output of the required type.
[0060] Such as image 3 As shown, in step S1 of the embodiment of the present invention, the input interface module receives common types of data such as text and host program interface. When multiple types of data are recei...
Embodiment 3
[0067] Figure 4 The structural block diagram of the SQL parsing device in the third embodiment of the present invention is shown. Reference Figure 4 , The SQL parsing device includes: a processor (processor) 401, a memory (memory) 402, a communication interface (Communications Interface) 403, and a bus 404;
[0068] among them,
[0069] The processor 401, the memory 402, and the communication interface 403 communicate with each other through the bus 404;
[0070] The communication interface 403 is used for information transmission between the communication devices of the SQL analysis device;
[0071] The processor 401 is configured to call program instructions in the memory 402 to execute the methods provided in the foregoing method embodiments, for example, including: an input interface module for mapping the received multiple types of data according to preset conversion rules It is a data stream in a preset format and sent to the SQL parsing engine; the SQL parsing engine is us...
PUM
Abstract
Description
Claims
Application Information
- R&D Engineer
- R&D Manager
- IP Professional
- Industry Leading Data Capabilities
- Powerful AI technology
- Patent DNA Extraction
Browse by: Latest US Patents, China's latest patents, Technical Efficacy Thesaurus, Application Domain, Technology Topic, Popular Technical Reports.
© 2024 PatSnap. All rights reserved.Legal|Privacy policy|Modern Slavery Act Transparency Statement|Sitemap|About US| Contact US: help@patsnap.com