CN115640447A - Data query method and device - Google Patents

Data query method and device Download PDF

Info

Publication number
CN115640447A
CN115640447A CN202211560642.8A CN202211560642A CN115640447A CN 115640447 A CN115640447 A CN 115640447A CN 202211560642 A CN202211560642 A CN 202211560642A CN 115640447 A CN115640447 A CN 115640447A
Authority
CN
China
Prior art keywords
data
target
query
client
group
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202211560642.8A
Other languages
Chinese (zh)
Inventor
郭临泉
马钊
王居满
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Bairong Zhixin Beijing Technology Co ltd
Original Assignee
Bairong Zhixin Beijing Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Bairong Zhixin Beijing Technology Co ltd filed Critical Bairong Zhixin Beijing Technology Co ltd
Priority to CN202211560642.8A priority Critical patent/CN115640447A/en
Publication of CN115640447A publication Critical patent/CN115640447A/en
Pending legal-status Critical Current

Links

Images

Abstract

The invention discloses a data query method and device, and relates to the technical field of data processing. The main technical scheme of the invention is as follows: receiving a data query request sent by a client, and responding to the data query request to display a target query configuration page on the client, wherein the target query configuration page comprises a basic index item, a data index item and an operator option; determining a data query condition based on a configuration operation of a user on the basic index item, the data index item and the operator option; generating a DSL query statement corresponding to the data query condition according to the data query condition and a preset logic grammar; executing the DSL query statement so as to obtain a data query result corresponding to the DSL query statement in an ES database; and sending the data query result to the client, and displaying the data query result. The invention is used for querying data.

Description

Data query method and device
Technical Field
The present invention relates to the field of data processing technologies, and in particular, to a data query method and apparatus.
Background
In the big data era, with the rapid rise and popularization of internet technology, the data volume generated by people in different fields is also increased dramatically. Especially for some enterprises, effective data needs to be screened from mass data as a support in the marketing process, so that an effective data retrieval mode is more important.
At present, most enterprises query data by using an Elasticsearch engine, and query analysis on mass data can be well realized. However, in the process of data query, different query sentences need to be written manually, and the format assembly is complex, so that the data query sentences are not accurate enough, the data query efficiency is low, the data query effect is poor, and the business requirements cannot be responded timely and accurately.
Disclosure of Invention
In view of the above problems, the present invention provides a data query method and apparatus, and mainly aims to improve the data query effect and timely and accurately respond to the service requirement.
In order to solve the technical problem, the invention provides the following scheme:
in a first aspect, the present invention provides a data query method, including:
receiving a data query request sent by a client, and responding to the data query request to display a target query configuration page on the client, wherein the target query configuration page comprises a basic index item, a data index item and an operator option;
determining a data query condition based on a configuration operation of a user on the basic index item, the data index item and the operator option;
generating a DSL query statement corresponding to the data query condition according to the data query condition and a preset logic grammar;
executing the DSL query statement so as to obtain a data query result corresponding to the DSL query statement in an ES database;
and sending the data query result to the client and displaying the data query result.
In a second aspect, the present invention provides a data query apparatus, including:
the system comprises a receiving unit, a display unit and a display unit, wherein the receiving unit is used for receiving a data query request sent by a client and responding to the data query request to display a target query configuration page on the client, and the target query configuration page comprises a basic index item, a data index item and an operator option;
a determining unit, configured to determine a data query condition based on a user configuration operation on the base index item, the data index item, and the operator option;
a first generating unit, configured to generate a DSL query statement corresponding to the data query condition according to the data query condition and a preset logic syntax;
an execution unit, configured to execute the DSL query statement so as to obtain a data query result corresponding to the DSL query statement in an ES database;
and the sending unit is used for sending the data query result to the client and displaying the data query result.
In order to achieve the above object, according to a third aspect of the present invention, there is provided a storage medium including a stored program, wherein when the program runs, a device on which the storage medium is located is controlled to execute the data query method of the first aspect.
In order to achieve the above object, according to a fourth aspect of the present invention, there is provided a processor for executing a program, wherein the program executes to perform the data query method of the first aspect.
By means of the technical scheme, the data query method and the data query device provided by the invention receive a data query request sent by a client when data is required to be queried, and display a target query configuration page on the client in response to the data query request, wherein the target query configuration page comprises a basic index item, a data index item and an operator option, namely, the corresponding target query configuration page can be displayed on the client when a user determines to query; determining a data query condition based on the configuration operation of a user on the basic index item, the data index item and the operator option; generating a DSL inquiry statement corresponding to the data inquiry condition according to the data inquiry condition and a preset logic grammar; executing the DSL query statement so as to obtain a data query result corresponding to the DSL query statement in an ES database; and sending the data query result to the client, and displaying the data query result. According to the data query scheme provided by the invention, codes do not need to be input manually, and a user can directly configure index items contained in a target query configuration page to generate different data query conditions, so that on one hand, the accuracy of the query conditions is ensured, on the other hand, the configuration efficiency of the query conditions can be improved, and further, the efficiency of the whole data query is improved, thereby improving the data query effect and ensuring that the business requirements can be responded timely and accurately in the query process.
The above description is only an overview of the technical solutions of the present invention, and the present invention can be implemented in accordance with the content of the description so as to make the technical means of the present invention more clearly understood, and the above and other objects, features, and advantages of the present invention will be more clearly understood.
Drawings
Various additional advantages and benefits will become apparent to those of ordinary skill in the art upon reading the following detailed description of the preferred embodiments. The drawings are only for purposes of illustrating the preferred embodiments and are not to be construed as limiting the invention. Also, like reference numerals are used to refer to like parts throughout the drawings. In the drawings:
FIG. 1 is a flow chart of a data query method provided by an embodiment of the invention;
FIG. 2 is a flow chart of another data query method provided by the embodiment of the invention;
FIG. 3 is a block diagram illustrating a data query device according to an embodiment of the present invention;
fig. 4 is a block diagram illustrating another data query device according to an embodiment of the present invention.
Detailed Description
Exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art.
In the big data age, with the rapid rise and popularization of internet technology, the data volume generated by people in different fields is also increased dramatically. Especially for some enterprises, effective data are often required to be screened from mass data as a support in the marketing process, so that an effective data retrieval mode is more important.
At present, most enterprises query data by using an Elasticissearch search engine, and query analysis of mass data can be well realized. However, in the process of data query, different query statements need to be written manually, and the format assembly is complex, so that the data query statements are not accurate enough, and the data query efficiency is low, thereby resulting in poor data query effect and failing to respond to business requirements timely and accurately. Therefore, an embodiment of the present invention provides a data query method, which improves a data query effect, so as to timely and accurately respond to a service requirement, and the specific implementation steps of the method are shown in fig. 1, and include:
101. and receiving a data query request sent by the client, and responding to the data query request to display a target query configuration page on the client.
The target query configuration page comprises a basic index item, a data index item and an operator option. It should be noted that, the execution main body of this embodiment is a server, the client includes, but is not limited to, an intelligent device such as a computer, a mobile phone, and the like, and when receiving a data query request, the client can analyze the data query request and respond based on the request content obtained by the analysis, specifically, the data query request is analyzed to obtain the request content corresponding to the data query request, and the request content includes a target guest group and a service type tag corresponding to the target guest group; determining an inquiry configuration page corresponding to the target guest group according to the service type tag corresponding to the target guest group, and taking the inquiry configuration page corresponding to the target guest group as a target inquiry configuration page; and sending the target query configuration page to the client, and displaying the target query configuration page. The request content may further include attribute information of a target guest group, such as information of a guest group name, a guest group number, a guest group source, storage time, and the like, and the target guest group may be one or multiple, and since the target guest group is a guest group substantially composed of guests having the same business type tag, when the target guest group is multiple, it is only necessary to ensure that the corresponding business type tags are the same, and the target query configuration page is set for the target guest group and may be generated when guest group data corresponding to the target guest group is stored. By displaying the target query configuration page at the client, the user is enabled to quickly view the base index items, the data index items, and the operator options in the target query configuration page in order to perform step 102.
102. And determining the data query condition based on the configuration operation of the user on the basic index item, the data index item and the operator option.
It should be noted that the basic index item is a basic information item included in each customer data in the customer group when receiving, AND includes but is not limited to attribute information items such as a customer unique number, an identification number, a telephone number, a name, a customer batch number, AND the like, AND the data index item refers to an additional information item in different dimensions correspondingly set after receiving AND before storing each customer data in the customer group, including but not limited to, attribute information items such as the location of the mobile phone number attribution, whether there is a credit record, the number of credits, the credit score, etc., operator options including but not limited to AND, OR, > =, <' >, <, betweeen, =, | = etc., wherein, the basic index item, the data index item AND the operator option can be configured by clicking AND inputting corresponding parameters on a target query configuration page by a user, corresponding data query conditions are generated, specifically, fields corresponding to the basic index item, the data index item AND the operator option can be preset, when a field value corresponding to the data index item (namely, a parameter input by the user) is obtained, a data query condition expression in a field format can be generated according to the fields corresponding to the basic index item, the data index item AND the operator option AND the field value, so that the subsequent step 103 is executed, through the above manner, the user can freely select AND quickly input the corresponding parameters according to the basic index item, the data index item AND the operator option, AND accordingly, the configuration efficiency of the user on the data query conditions is improved.
103. And generating a DSL inquiry statement corresponding to the data inquiry condition according to the data inquiry condition and the preset logic grammar.
It should be noted that the preset logic syntax is a specific format preset by the user for converting the field expression into the DSL statement, and the data query condition can be converted into the corresponding DSL query statement through the preset logic syntax, so as to execute the subsequent step 104.
104. And executing the DSL query statement so as to obtain a data query result corresponding to the DSL query statement in the ES database.
It should be noted that, since the DSL query statement is already obtained in step 103, in this step, the DSL query statement may be directly executed, so that the stored data meeting the query requirement of the DSL query statement in the target guest group of the ES database can be obtained, and the stored data meeting the query requirement of the DSL query statement is used as a data query result, where the data query result may be the number of the stored data meeting the query requirement of the DSL query statement, or the sorted stored data meeting the query requirement of the DSL query statement, which is not limited in this embodiment.
105. And sending the data query result to the client and displaying the data query result.
It should be noted that, after the data query result is obtained, the data query result may be sent to the client, so that the client displays the data query result, and a user performs subsequent operations according to the data query result.
Further, in order to reduce the number of the displayed data query results and improve the query precision, the user may also mark the range index item in the query configuration page for configuration, specifically, the target query configuration page further includes the range index item; before sending the data query result to the client and displaying the data query result, the method further includes: determining a data limitation condition based on the configuration operation of the user on the range index item; sending the data query result to the client, and displaying the data query result, wherein the data query result comprises: and sending the data query result to the client, and displaying the data query result according to the data limitation condition. The range index item is specifically a quantity index, that is, the quantity in the query result is limited, exemplarily, the parameter corresponding to the range index item is 1000, if the quantity of the queried data is more than 1000, only the first 1000 pieces of data are displayed, and if the quantity of the queried data is less than 1000, the quantity of the queried data is displayed.
Based on the implementation manner of fig. 1, it can be seen that in the data query method provided by the present invention, when data needs to be queried, a data query request sent by a client is received, and a target query configuration page is displayed at the client in response to the data query request, where the target query configuration page includes a basic index item, a data index item, and an operator option, that is, when a user determines a query, a corresponding target query configuration page can be displayed at the client; determining a data query condition based on configuration operation of a user on the basic index item, the data index item and the operator option; generating a DSL inquiry statement corresponding to the data inquiry condition according to the data inquiry condition and a preset logic grammar; executing the DSL query statement so as to obtain a data query result corresponding to the DSL query statement in the ES database; and sending the data query result to the client and displaying the data query result. According to the data query scheme provided by the invention, manual code input is not needed, and a user can directly configure the index items contained in the target query configuration page to generate different data query conditions, so that on one hand, the accuracy of the query conditions is ensured, on the other hand, the configuration efficiency of the query conditions can be improved, and further, the efficiency of overall data query is improved, thereby improving the data query effect and ensuring that the business requirements can be timely and accurately responded in the query process.
Further, a preferred embodiment of the present invention is a detailed description of a storage process before data query based on the foregoing fig. 1, and specific steps of the detailed description are shown in fig. 2, and include:
201. and acquiring client data corresponding to a target client group, wherein the target client group is a client group formed by clients with the same service type label.
It should be noted that the client data corresponding to the target guest group is obtained from the enterprise server, where the client data includes, but is not limited to, attribute information such as a unique client number, an identification number, a telephone number, a name, a client batch number, and the like, and is preset and stored in the enterprise server, the target guest group is a client group formed by clients having the same service type label, that is, service type labels corresponding to different guest groups are different, and the service type includes, but is not limited to, a declaration completion, a first-aid login, and the like, that is, when the client data corresponding to the target guest group is obtained, the service type label corresponding to the target guest group can be obtained.
202. And setting the product items corresponding to the target customer group based on the business type labels corresponding to the target customer group.
It should be noted that, because high-quality customers are often required to be screened out for targeted marketing in the enterprise marketing process, the customer intention cannot be accurately analyzed only based on basic information in the customer data of the target customer group, and each customer in the target customer group also needs to be evaluated in different dimensions, and the product items are index items in different dimensions, including but not limited to application scores, credit scores, mobile phone number attributions, mobile phone card types, loan times, whether to loan or not, and other index items in different dimensions related to the service types and capable of being used for evaluating the customer intention, so that the product items corresponding to the target customer group can be added on the basis of the customer data corresponding to the target customer group to perform the subsequent step 203.
203. And calling the product item to determine a product result corresponding to the target customer group.
It should be noted that, the product result is based on the index item result described in the foregoing step 202, when the product result is a result of evaluating the score categories such as applying for a score, granting a credit, and the like, the user data corresponding to each customer in the target customer group needs to be input as a sample into a preset existing or customized model to obtain a corresponding evaluation score, and when the product result is a result of actually recording such as loan times, loan availability, and the like, the user data corresponding to each customer needs to be used as a sample and corresponding actual records are obtained from different bank servers, so as to perform the subsequent step 204.
204. And generating an inquiry configuration page corresponding to the target guest group according to the customer data corresponding to the target guest group and the product result corresponding to the target guest group, and adding a service type label corresponding to the target guest group in the inquiry configuration page.
The query configuration page comprises a basic index item, a data index item, an operator option and a range index item. It should be noted that, the query configuration page is a query condition configuration page capable of responding to a data query request and displaying on a client, and a corresponding data query condition can be generated through configuration operations of a basic index item, a data index item and an operator option in the query configuration page by a user, so that the user can perform free configuration, and a specific generation process is as follows: taking the attribute name corresponding to the customer data as a basic index item; taking the attribute name corresponding to the product result as a data index item; and generating a query configuration page corresponding to the target guest group based on the basic index item, the data index item and the operator option. Wherein the attribute names include but are not limited to customer unique number, identification number, phone number, name, customer lot number, etc., the product names include but are not limited to application score, credit score, mobile phone number attribution, mobile phone card type, loan times, loan OR not, etc., the operator options include but are not limited to AND, OR, > =, < =, >, <, >, BETWEEN, =, >, | =, | = etc., AND the range indicator term refers to the quantity indicator, after the query configuration page corresponding to the target guest group is generated, the service type tag corresponding to the target guest group is added to the query configuration page, so that in the subsequent query process, after the target guest group is determined, the query configuration page corresponding to the target guest group can be determined based on the service type tag corresponding to the target guest group, AND thus data search is performed on the target guest group, AND the accuracy of the subsequent query process is improved.
205. And forming the customer data corresponding to the target customer group and the product result corresponding to the target customer group into data to be stored corresponding to the target customer group according to a preset format, and storing the data to be stored corresponding to the target customer group and the query configuration page corresponding to the target customer group into the ES database.
The preset format is a storage format corresponding to a nested type, and the customer data corresponding to the target guest group and the product results corresponding to the target guest group can be stored in the ES database in a nested manner layer by layer through the preset format, where the ES database is an Elasticsearch database, and the query configuration page corresponding to the target guest group is also stored in the ES database while the data to be stored is stored, so that data search is performed on the data to be stored corresponding to the target guest group on the basis of the query configuration page corresponding to the target guest group in the subsequent process.
Further, in order to improve convenience of setting the product items, after setting the product items corresponding to the target guest group based on the service type tags corresponding to the target guest group, the method further includes: and establishing an incidence relation between the business type label corresponding to the target customer group and the product item corresponding to the target customer group. The association relationship may be set based on the association relationship table by generating the association relationship table, or may be set based on the corresponding tag by setting the tag, which is not limited in this embodiment. By the method, convenience for setting product items can be improved when different customer groups with the same business type label are processed.
Further, as an implementation of the method embodiment shown in fig. 1-2, an embodiment of the present invention provides a data query device, which is used for improving a data query effect, so as to timely and accurately respond to a service requirement. The embodiment of the apparatus corresponds to the foregoing method embodiment, and details in the foregoing method embodiment are not described in detail again in this embodiment for convenience of reading, but it should be clear that the apparatus in this embodiment can correspondingly implement all the contents in the foregoing method embodiment. As shown in fig. 3 in detail, the apparatus includes:
a receiving unit 301, configured to receive a data query request sent by a client, and display a target query configuration page on the client in response to the data query request, where the target query configuration page includes a basic index item, a data index item, and an operator option;
a determining unit 302, configured to determine a data query condition based on a user configuration operation on the base indicator item, the data indicator item, and the operator option;
a first generating unit 303, configured to generate a DSL query statement corresponding to the data query condition according to the data query condition and a preset logic syntax;
an executing unit 304, configured to execute the DSL query statement so as to obtain a data query result corresponding to the DSL query statement in an ES database;
a sending unit 305, configured to send the data query result to the client, and display the data query result.
Further, as shown in fig. 4, the apparatus further includes:
an obtaining unit 306, configured to obtain, before the receiving unit 301, client data corresponding to a target customer group, where the target customer group is a customer group formed by customers with the same service type tag;
a setting unit 307, configured to set a product item corresponding to the target customer group based on the service type tag corresponding to the target customer group;
the calling unit 308 is configured to call the product item to determine a product result corresponding to the target customer group;
a second generating unit 309, configured to generate an inquiry configuration page corresponding to the target guest group according to the customer data corresponding to the target guest group and the product result corresponding to the target guest group, and add a service type tag corresponding to the target guest group to the inquiry configuration page;
the storage unit 310 is configured to compose, according to a preset format, customer data corresponding to the target guest group and a product result corresponding to the target guest group into to-be-stored data corresponding to the target guest group, and store the to-be-stored data corresponding to the target guest group and the query configuration page corresponding to the target guest group in an ES database.
Further, as shown in fig. 4, the second generating unit 309 is specifically configured to,
taking the attribute name corresponding to the customer data as a basic index item;
taking the attribute name corresponding to the product result as a data index item;
and generating a query configuration page corresponding to the target guest group based on the basic index item, the data index item and the operator option.
Further, as shown in fig. 4, the apparatus further includes:
a building unit 311, configured to build, after the setting unit 307, an association relationship between the service type tag corresponding to the target guest group and the product item corresponding to the target guest group.
Further, as shown in fig. 4, the receiving unit 301 includes:
the parsing module 3011 is configured to parse the data query request to obtain request content corresponding to the data query request, where the request content includes a target guest group and a service type tag corresponding to the target guest group;
a determining module 3012, configured to determine, according to the service type tag corresponding to the target guest group, an inquiry configuration page corresponding to the target guest group, and use the inquiry configuration page corresponding to the target guest group as a target inquiry configuration page;
a sending module 3013, configured to send the target query configuration page to the client, and display the target query configuration page.
Further, as shown in fig. 4, the target query configuration page further includes a range index item; the device further comprises:
the determining unit 302 is further configured to determine a data limitation condition based on a configuration operation of the user on the range index item before the sending unit 305;
the sending unit 305 is specifically configured to send, in particular,
and sending the data query result to the client, and displaying the data query result according to a data limiting condition.
Further, an embodiment of the present invention further provides a storage medium, where the storage medium is used to store a computer program, where the computer program controls, when running, a device in which the storage medium is located to execute the data query method described in fig. 1-2 above.
Further, an embodiment of the present invention further provides a processor, where the processor is configured to execute a program, where the program executes the data query method described in fig. 1-2.
In the foregoing embodiments, the descriptions of the respective embodiments have respective emphasis, and for parts that are not described in detail in a certain embodiment, reference may be made to the related descriptions of other embodiments.
It will be appreciated that the relevant features of the method and apparatus described above may be referred to one another. In addition, "first", "second", and the like in the above embodiments are used to distinguish the embodiments, and do not represent merits of the embodiments.
It can be clearly understood by those skilled in the art that, for convenience and simplicity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
The algorithms and displays presented herein are not inherently related to any particular computer, virtual machine, or other apparatus. Various general purpose systems may also be used with the teachings herein. The required structure for constructing such a system will be apparent from the description above. Moreover, the present invention is not directed to any particular programming language. It is appreciated that a variety of programming languages may be used to implement the teachings of the present invention as described herein, and any descriptions of specific languages are provided above to disclose the best mode of the invention.
Further, the memory may include volatile memory in a computer readable medium, random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM), and the memory includes at least one memory chip.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and so forth) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include forms of volatile memory in a computer readable medium, random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). The memory is an example of a computer-readable medium.
Computer-readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static Random Access Memory (SRAM), dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), read Only Memory (ROM), electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information that can be accessed by a computing device. As defined herein, a computer readable medium does not include a transitory computer readable medium such as a modulated data signal and a carrier wave.
It should also be noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrases "comprising a," "8230," "8230," or "comprising" does not exclude the presence of additional identical elements in the process, method, article, or apparatus comprising the element.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and so forth) having computer-usable program code embodied therein.
The above are merely examples of the present application and are not intended to limit the present application. Various modifications and changes may occur to those skilled in the art. Any modification, equivalent replacement, improvement or the like made within the spirit and principle of the present application shall be included in the scope of the claims of the present application.

Claims (14)

1. A method of querying data, comprising:
receiving a data query request sent by a client, and responding to the data query request to display a target query configuration page on the client, wherein the target query configuration page comprises a basic index item, a data index item and an operator option;
determining a data query condition based on a configuration operation of a user on the basic index item, the data index item and the operator option;
generating a DSL query statement corresponding to the data query condition according to the data query condition and a preset logic grammar;
executing the DSL query statement so as to obtain a data query result corresponding to the DSL query statement in an ES database;
and sending the data query result to the client, and displaying the data query result.
2. The method of claim 1, wherein before receiving a data query request sent by a client and displaying a target query configuration page at the client in response to the data query request, the method further comprises:
obtaining client data corresponding to a target client group, wherein the target client group is a client group formed by clients with the same service type labels;
setting a product item corresponding to the target guest group based on the business type label corresponding to the target guest group;
calling the product item to determine a product result corresponding to the target customer group;
generating a query configuration page corresponding to the target customer group according to the customer data corresponding to the target customer group and the product result corresponding to the target customer group, and adding a service type label corresponding to the target customer group in the query configuration page;
and forming the customer data corresponding to the target guest group and the product result corresponding to the target guest group into data to be stored corresponding to the target guest group according to a preset format, and storing the data to be stored corresponding to the target guest group and the query configuration page corresponding to the target guest group into an ES database.
3. The method of claim 2, wherein generating the query configuration page corresponding to the target customer group according to the customer data corresponding to the target customer group and the product result corresponding to the target customer group comprises:
taking the attribute name corresponding to the customer data as a basic index item;
taking the attribute name corresponding to the product result as a data index item;
and generating a query configuration page corresponding to the target guest group based on the basic index item, the data index item and the operator option.
4. The method of claim 2, wherein after setting the product item corresponding to the target guest group based on the business type tag corresponding to the target guest group, the method further comprises:
and establishing an incidence relation between the business type label corresponding to the target guest group and the product item corresponding to the target guest group.
5. The method of claim 1, wherein receiving a data query request sent by a client, and displaying a target query configuration page on the client in response to the data query request comprises:
analyzing the data query request to obtain request content corresponding to the data query request, wherein the request content comprises a target guest group and a service type label corresponding to the target guest group;
determining an inquiry configuration page corresponding to the target guest group according to the service type tag corresponding to the target guest group, and taking the inquiry configuration page corresponding to the target guest group as a target inquiry configuration page;
and sending the target query configuration page to the client, and displaying the target query configuration page.
6. The method of claim 1, wherein the target query configuration page further comprises a scope indicator term; before sending the data query result to the client and displaying the data query result, the method further includes:
determining a data limitation condition based on the configuration operation of the user on the range index item;
sending the data query result to the client, and displaying the data query result, including:
and sending the data query result to the client, and displaying the data query result according to the data limiting condition.
7. A data query apparatus, comprising:
the system comprises a receiving unit, a display unit and a display unit, wherein the receiving unit is used for receiving a data query request sent by a client and responding to the data query request to display a target query configuration page on the client, and the target query configuration page comprises a basic index item, a data index item and an operator option;
a determining unit, configured to determine a data query condition based on a configuration operation of a user on the base index item, the data index item, and the operator option;
a first generating unit, configured to generate a DSL query statement corresponding to the data query condition according to the data query condition and a preset logic syntax;
an execution unit, configured to execute the DSL query statement so as to obtain a data query result corresponding to the DSL query statement in an ES database;
and the sending unit is used for sending the data query result to the client and displaying the data query result.
8. The apparatus of claim 7, further comprising:
the acquisition unit is used for acquiring client data corresponding to a target customer group before the receiving unit, wherein the target customer group is a customer group formed by customers with the same service type label;
the setting unit is used for setting the product items corresponding to the target customer group based on the business type labels corresponding to the target customer group;
the calling unit is used for calling the product item to determine a product result corresponding to the target customer group;
a second generating unit, configured to generate an inquiry configuration page corresponding to the target guest group according to the customer data corresponding to the target guest group and the product result corresponding to the target guest group, and add a service type tag corresponding to the target guest group to the inquiry configuration page;
and the storage unit is used for forming the customer data corresponding to the target guest group and the product result corresponding to the target guest group into data to be stored corresponding to the target guest group according to a preset format, and storing the data to be stored corresponding to the target guest group and the query configuration page corresponding to the target guest group into an ES database.
9. The apparatus according to claim 8, characterized in that the second generating unit, in particular for,
taking the attribute name corresponding to the customer data as a basic index item;
taking the attribute name corresponding to the product result as a data index item;
and generating a query configuration page corresponding to the target guest group based on the basic index item, the data index item and the operator option.
10. The apparatus of claim 8, further comprising:
and the building unit is used for building the association relationship between the business type label corresponding to the target guest group and the product item corresponding to the target guest group after the setting unit.
11. The apparatus of claim 7, wherein the receiving unit comprises:
the analysis module is used for analyzing the data query request to obtain request content corresponding to the data query request, wherein the request content comprises a target guest group and a service type label corresponding to the target guest group;
the determining module is used for determining a query configuration page corresponding to the target guest group according to the business type tag corresponding to the target guest group, and taking the query configuration page corresponding to the target guest group as a target query configuration page;
and the sending module is used for sending the target query configuration page to the client and displaying the target query configuration page.
12. The apparatus of claim 7, wherein the target query configuration page further comprises a scope index term; the device further comprises:
the determining unit is further used for determining a data limiting condition based on the configuration operation of the user on the range index item before the sending unit;
the sending unit is specifically configured to send, to the mobile terminal,
and sending the data query result to the client, and displaying the data query result according to the data limiting condition.
13. A storage medium, characterized in that the storage medium comprises a stored program, wherein when the program runs, a device on which the storage medium is located is controlled to execute the data query method according to any one of claims 1 to 6.
14. A processor, configured to execute a program, wherein the program executes the data query method according to any one of claims 1 to 6.
CN202211560642.8A 2022-12-07 2022-12-07 Data query method and device Pending CN115640447A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211560642.8A CN115640447A (en) 2022-12-07 2022-12-07 Data query method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211560642.8A CN115640447A (en) 2022-12-07 2022-12-07 Data query method and device

Publications (1)

Publication Number Publication Date
CN115640447A true CN115640447A (en) 2023-01-24

Family

ID=84947930

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211560642.8A Pending CN115640447A (en) 2022-12-07 2022-12-07 Data query method and device

Country Status (1)

Country Link
CN (1) CN115640447A (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111914135A (en) * 2020-07-24 2020-11-10 平安证券股份有限公司 Data query method and device, electronic equipment and storage medium
CN114064733A (en) * 2021-11-29 2022-02-18 中国平安财产保险股份有限公司 Database query method, device, equipment and medium suitable for local client
CN114625458A (en) * 2022-02-16 2022-06-14 中国建设银行股份有限公司 Page data processing method and device, electronic equipment and storage medium

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111914135A (en) * 2020-07-24 2020-11-10 平安证券股份有限公司 Data query method and device, electronic equipment and storage medium
CN114064733A (en) * 2021-11-29 2022-02-18 中国平安财产保险股份有限公司 Database query method, device, equipment and medium suitable for local client
CN114625458A (en) * 2022-02-16 2022-06-14 中国建设银行股份有限公司 Page data processing method and device, electronic equipment and storage medium

Similar Documents

Publication Publication Date Title
US8799854B2 (en) Reusing software development assets
US11074250B2 (en) Technologies for implementing ontological models for natural language queries
CN109284323B (en) Management method and device for detection data
CN110866091B (en) Data retrieval method and device
CN108920543B (en) Query and interaction method and device, computer device and storage medium
CN111078776A (en) Data table standardization method, device, equipment and storage medium
US20220129491A1 (en) Method for supporting agent and computing device thereof
CN113360676A (en) Method and device for determining potential relation of enterprise based on knowledge graph
US20210192433A1 (en) Commodity exhibition management method, management server, client and system
CN113835692A (en) Dictionary data processing method and device, electronic equipment and computer storage medium
CN110737706A (en) Data management method, device, equipment and computer readable storage medium
CN114297204A (en) Data storage and retrieval method and device for heterogeneous data source
CN116883111A (en) Commodity recommendation text generation method, device and equipment
CN109145092A (en) A kind of database update, intelligent answer management method, device and its equipment
CN111177093A (en) Method, device and medium for sharing scientific and technological resources
CN116401704A (en) Sensitive data identification method, electronic equipment and storage medium
CN115640447A (en) Data query method and device
CN108241622B (en) Query script generation method and device
CN112418260A (en) Model training method, information prompting method, device, equipment and medium
CN112148939A (en) Data processing method and device and electronic equipment
CN111753020A (en) Method and device for establishing relational network model
CN112580915A (en) Project milestone determination method and device, storage medium and electronic equipment
CN112181407A (en) Service implementation processing method, device, system, electronic equipment and storage medium
CN113641644B (en) Data pushing system
CN113220187B (en) Micro banking business interaction method and related equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20230124