[go: up one dir, main page]

CN109710859A - Data query method and apparatus - Google Patents

Data query method and apparatus Download PDF

Info

Publication number
CN109710859A
CN109710859A CN201910053418.1A CN201910053418A CN109710859A CN 109710859 A CN109710859 A CN 109710859A CN 201910053418 A CN201910053418 A CN 201910053418A CN 109710859 A CN109710859 A CN 109710859A
Authority
CN
China
Prior art keywords
inquiry request
query
data
data inquiry
response
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
CN201910053418.1A
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.)
Beijing ByteDance Network Technology Co Ltd
Original Assignee
Beijing ByteDance Network 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 Beijing ByteDance Network Technology Co Ltd filed Critical Beijing ByteDance Network Technology Co Ltd
Priority to CN201910053418.1A priority Critical patent/CN109710859A/en
Publication of CN109710859A publication Critical patent/CN109710859A/en
Pending legal-status Critical Current

Links

Landscapes

  • Information Transfer Between Computers (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

Embodiment of the disclosure discloses data query method and apparatus.One specific embodiment of this method includes: the data inquiry request in response to receiving terminal transmission, and data inquiry request is resolved at least one query statement;It based on the query statement at least one query statement, is inquired in target database, obtains query result;By query result storage to target storage position;It include the prompt information of the location information of target storage position to terminal push.The embodiment, which is realized, exports to target storage position for data.

Description

Data query method and apparatus
Technical field
Embodiment of the disclosure is related to field of computer technology, and in particular to data query method and apparatus.
Background technique
With the fast development of Internet technology, a large amount of data can be all generated all the time.These data often store In the database.Under many scenes, need to inquire the data in database from different granularities.Work as non-technical personnel Ordinary user need to inquire the data in database, when especially being inquired from smaller granularity, need to compile Corresponding structured query sentence is write to inquire database.
Summary of the invention
Embodiment of the disclosure proposes data query method and apparatus.
In a first aspect, embodiment of the disclosure provides a kind of data query method, this method comprises: in response to receiving The data inquiry request that terminal is sent, resolves at least one query statement for data inquiry request;Based at least one inquiry Query statement in sentence, is inquired in target database, obtains query result;Query result storage is stored to target Position;It include the prompt information of the location information of target storage position to terminal push.
In some embodiments, the data inquiry request sent in response to receiving terminal, data inquiry request is parsed For at least one query statement, comprising: in response to receiving the data inquiry request of terminal transmission, determine that data inquiry request is It is no legal;In response to determining that data inquiry request is legal, data inquiry request is resolved at least one query statement.
In some embodiments, the data inquiry request sent in response to receiving terminal, data inquiry request is parsed For at least one query statement, comprising: in response to receiving the data inquiry request of terminal transmission, obtain the classification of query engine Information;According to the classification information of query engine, data inquiry request is resolved at least one query statement.
In some embodiments, before including the prompt information of location information of target storage position to terminal push, This method further include: update inquiry status information corresponding with data inquiry request.
In some embodiments, the data inquiry request sent in response to receiving terminal, data inquiry request is parsed For at least one query statement, comprising: in response to receiving at least one data inquiry request of terminal transmission, at least one A inquiry request is ranked up at least one inquiry request according to the priority level information, obtains inquiry request sequence;For looking into The inquiry request in request sequence is ask, which is resolved at least one query statement.
Second aspect, embodiment of the disclosure provide a kind of data query device, which includes: resolution unit, quilt It is configured to receive the data inquiry request of terminal transmission, data inquiry request is resolved at least one inquiry language Sentence;Query unit is configured to be inquired in target database based on the query statement at least one query statement, Obtain query result;Storage unit is configured to store query result to target storage position;Push unit is configured to It include the prompt information of the location information of target storage position to terminal push.
In some embodiments, resolution unit is further configured to: the data query in response to receiving terminal transmission Request, determines whether data inquiry request is legal;In response to determining that data inquiry request is legal, data inquiry request is resolved to At least one query statement.
In some embodiments, resolution unit is further configured to: the data query in response to receiving terminal transmission Request, obtains the classification information of query engine;According to the classification information of query engine, data inquiry request is resolved at least one A query statement.
In some embodiments, device further include: with new unit, be configured to update corresponding with data inquiry request Inquire status information.
In some embodiments, resolution unit is further configured to: in response to receive terminal transmission at least one Data inquiry request is ranked up at least one inquiry request according to the priority level information at least one inquiry request, Obtain inquiry request sequence;For the inquiry request in inquiry request sequence, which is resolved at least one Query statement.
The third aspect, embodiment of the disclosure provide a kind of server, which includes: one or more processing Device;Storage device is stored thereon with one or more programs;When said one or multiple programs are by said one or multiple processing Device executes, so that said one or multiple processors realize the method as described in implementation any in first aspect.
Fourth aspect, embodiment of the disclosure provide a kind of computer-readable medium, are stored thereon with computer program, The method as described in implementation any in first aspect is realized when above procedure is executed by processor.
The method and apparatus that embodiment of the disclosure provides can be asked in response to receiving the data query of terminal transmission It asks, data inquiry request is resolved at least one query statement.On this basis, based on looking at least one query statement Sentence is ask, is inquired in target database, obtains query result.Finally, by query result storage to target storage position, And the prompt information to location information of the terminal push including target storage position.To allow user to request by sending The inquiry of database, and data are exported into target storage position.Compared with prior art, it does not need user and writes to look into Ask sentence, so that it may inquire database.
Detailed description of the invention
By reading a detailed description of non-restrictive embodiments in the light of the attached drawings below, the disclosure is other Feature, objects and advantages will become more apparent upon:
Fig. 1 is that one embodiment of the disclosure can be applied to exemplary system architecture figure therein;
Fig. 2 is the flow chart according to one embodiment of the data query method of the disclosure;
Fig. 3 is the schematic diagram of an application scenarios of data query method according to an embodiment of the present disclosure;
Fig. 4 is the flow chart according to another embodiment of the data query method of the disclosure;
Fig. 5 is the structural schematic diagram according to one embodiment of the data query device of the disclosure;
Fig. 6 is adapted for the structural schematic diagram for realizing the electronic equipment of embodiment of the disclosure.
Specific embodiment
The disclosure is described in further detail with reference to the accompanying drawings and examples.It is understood that this place The specific embodiment of description is used only for explaining that correlation is open, rather than the restriction to the disclosure.It also should be noted that being Convenient for description, is illustrated only in attached drawing and to related disclose relevant part.
It should be noted that in the absence of conflict, the feature in embodiment and embodiment in the disclosure can phase Mutually combination.The disclosure is described in detail below with reference to the accompanying drawings and in conjunction with the embodiments.
Fig. 1 is shown can be using the data query method of embodiment of the disclosure or the exemplary system of data query device System framework 100.
As shown in Figure 1, system architecture 100 may include terminal device 101,102,103, network 104,105 and of server Database 106.Network 104 between terminal device 101,102,103 and server 105 to provide the medium of communication link. Network 104 may include various connection types, such as wired, wireless communication link or fiber optic cables etc..
User can be used terminal device 101,102,103 and be interacted by network 104 with server 105, to receive or send out Send message etc..Various client applications, such as news category application, shopping class can be installed on terminal device 101,102,103 Using, video class application etc..
Terminal device 101,102,103 can be hardware, be also possible to software.When terminal device 101,102,103 is hard When part, it can be and support to send request and receive the various electronic equipments of information.When terminal device 101,102,103 is software When, it may be mounted in above-mentioned electronic equipment.Multiple softwares or software module may be implemented into (such as providing distribution in it Service), single software or software module also may be implemented into.It is not specifically limited herein.
Server 105 can be to provide the server of various services, such as to the application on terminal device 101,102,103 The background server supported is provided.The data inquiry request that background server can be sent in response to receiving terminal, to data Inquiry request carries out the processing such as parsing.And related prompt message is pushed to terminal device.
Database 106 can be used for storing Various types of data.Database 106 and server 105 communicate to connect.As needed, It can dispose on server 105, can also be deployed on the electronic equipment of communication connection.According to realization needs, server 105 On can be with installation database management software.In addition, database 106 also can according to need and be implemented as distributed data base.
It should be noted that data query method provided by embodiment of the disclosure is generally executed by server 105, phase Ying Di, data query device are generally positioned in server 105.
It should be noted that server can be hardware, it is also possible to software.When server is hardware, may be implemented At the distributed server cluster that multiple servers form, individual server also may be implemented into.It, can when server is software To be implemented as multiple softwares or software module (such as providing Distributed Services), single software or software also may be implemented into Module.It is not specifically limited herein.
It should be understood that the number of terminal device, network and server in Fig. 1 is only schematical.According to realization need It wants, can have any number of terminal device, network and server.
With continued reference to Fig. 2, the process 200 of one embodiment of the data query method according to the disclosure is shown.The number According to querying method, comprising the following steps:
Step 201, the data inquiry request sent in response to receiving terminal, resolves at least one for data inquiry request A query statement.
In the present embodiment, the executing subject (server 105 of example as shown in figure 1) of data query method is in response to receiving Data inquiry request, can be resolved at least one query statement by the data inquiry request that terminal is sent.Wherein, query statement can To be the sentence of various structurings for being increased to database, being deleted, changed, looked into.
In the present embodiment, data inquiry request may include at least one field of data for needing to inquire and each The value of field.By taking user data as an example, data inquiry request may include " gender " of user data this field and this The value of a field, i.e. " male " or " female ".Due to may include at least one field in data inquiry request.Above-mentioned executing subject Data inquiry request can be resolved to at least one query statement.
As an example, above-mentioned executing subject can be parsed data inquiry request by inquiring preset mapping table For at least one query statement.Wherein, can store in mapping table data inquiry request and it is corresponding at least one look into Ask sentence.As an example, data inquiry request can also be resolved at least one according to preset logic by above-mentioned executing subject Query statement.
Step 202, it based on the query statement at least one query statement, is inquired, is obtained in target database Query result.
In the present embodiment, above-mentioned executing subject can based at least one obtained query statement in step 201, It is inquired in target database, obtains query result.
As an example, above-mentioned executing subject can also be using query engines such as the middlewares, such as presto of some open sources It is inquired.In practice, the query engines such as presto externally provide interface.To which above-mentioned executing subject can be by least one Query statement is by interface input inquiry engine, to obtain query result.Here, query result can be at least one Query statement is inquired respectively, and the obtained sub- result of inquiry summarizes.In general, query result can be the various numbers inquired According to.Wherein, target database can be arbitrary database.The determination of target database can be is specified by technical staff, It is also possible to according to certain condition determination.It is right for each query statement institute at least one query statement in practice The target database answered can be identical database, be also possible to different databases.
In some optional implementations of the present embodiment, in response to receiving the data inquiry request of terminal transmission, Data inquiry request is resolved at least one query statement, comprising: in response to receiving the data inquiry request of terminal transmission, Obtain the classification information of query engine;According to the classification information of query engine, data inquiry request is resolved at least one and is looked into Ask sentence.
In these implementations, the query statement as corresponding to different classes of query engine may be different.Therefore, Above-mentioned executing subject can according to the classification information of query engine, by data inquiry request resolve to it is corresponding at least one Query statement.Specifically, as an example, inquiry table corresponding with the query engine of each classification can be preestablished.To Above-mentioned executing subject can determine corresponding inquiry table according to the classification information of query engine.And then according to corresponding inquiry Data inquiry request is resolved at least one query statement by table.
Step 203, query result is stored to target storage position.
In the present embodiment, above-mentioned executing subject can store query result to target storage position.Wherein, target is deposited Storage space, which is set, can be arbitrary storage location.Target storage position can be the storage location that technical staff specifies, and be also possible to The storage location determined according to certain condition.
Step 204, to the prompt information of location information of the terminal push including target storage position.
In the present embodiment, above-mentioned executing subject can push the prompt letter of the location information including storage location to terminal Breath.According to actual needs, prompt information can be various forms of information.It may include target storage position in prompt information Location information, so that user obtains query result from target storage position.
With continued reference to the schematic diagram that Fig. 3, Fig. 3 are according to the application scenarios of the data query method of the present embodiment.? In the application scenarios of Fig. 3, executing subject can be server 301.Server 301 and terminal device (laptop) 302 are logical Letter connection.The data inquiry request 303 that server 301 is sent in response to receiving terminal device 302, data query can be asked 303 are asked to resolve at least one query statement 304.Later, server 301 can be based at least one query statement 304 Each query statement is inquired in target database 305, obtains query result 306.On this basis, by query result Store target storage position.Finally, server 301 can push the position including target storage position to terminal device 302 The prompt information of information.
The method that embodiment of the disclosure provides, the data inquiry request that can be sent in response to receiving terminal, will count It is investigated that asking request analysis is at least one query statement.On this basis, based on the query statement at least one query statement, It is inquired in target database, obtains query result.Finally, by query result storage to target storage position, Yi Jixiang Terminal push includes the prompt information of the location information of target storage position.To allow user by sending request completion pair The inquiry of database, and data are exported into target storage position.Compared with prior art, it does not need user and writes inquiry language Sentence, so that it may complete to data query.
With further reference to Fig. 4, it illustrates the processes 400 of another embodiment of data query method.The data query The 400 of method, comprising the following steps:
Step 401, the data inquiry request sent in response to receiving terminal, determines whether data inquiry request is legal.
In the present embodiment, the executing subject of data query method is asked in response to receiving the data query of terminal transmission It asks, can determine whether the request of data received is legal.Specifically, above-mentioned executing subject can in several ways, from Multiple dimensions determine whether data inquiry request is legal.For example, the field for the data for including in being requested with verify data whether It is legal.For another example, it is default whether the value of the field for the data that can included with verify data inquiry request is comprised in the field Value set in.It is different according to the dimension of required verifying in practice, it can be determined in different ways.To test For whether card field is legal, whether it can inquire in preset set of fields comprising the field.And taking for verifying field Whether whether it is legal to be worth, can inquire in preset value set comprising the value.
Step 402, in response to determining that data inquiry request is legal, data inquiry request is resolved at least one inquiry language Sentence.
In the present embodiment, above-mentioned executing subject can ask data query in response to determining that data inquiry request is legal It asks and resolves at least one query statement.Specific implementation can be with reference to the step 201 in the corresponding embodiment of Fig. 2, herein no longer It repeats.
Step 403, it based on the query statement at least one query statement, is inquired, is obtained in target database Query result.
Step 404, query result is stored to target storage position.
In the present embodiment, the specific implementation of step 403-404 and its brought technical effect can be corresponding with reference to Fig. 2 Embodiment in step 202-203.
Step 405, inquiry status information corresponding with data inquiry request is updated.
In the present embodiment, above-mentioned executing subject can by query result storage to after target storage position, update with The corresponding inquiry status information of data inquiry request.In practice, inquiry status information can store local in above-mentioned executing subject. Also it can according to need, also may be displayed on above-mentioned terminal.User can check inquiry status information by terminal as a result, and When understand inquiry state.
Step 406, to the prompt information of location information of the terminal push including target storage position.
In the present embodiment, the specific implementation of step 406 and its brought technical effect can refer to the corresponding reality of Fig. 2 Apply the step 204 in example.
In some optional implementations of the present embodiment, in response to receiving the data inquiry request of terminal transmission, Data inquiry request is resolved at least one query statement, comprising: in response to receiving at least one data of terminal transmission Inquiry request is ranked up at least one inquiry request according to the priority level information, obtains at least one inquiry request Inquiry request sequence;For the inquiry request in inquiry request sequence, which is resolved at least one inquiry Sentence.
In these implementations, each data inquiry request may include the priority level information.The priority level information can For indicating the priority level of processing data inquiry request.According to actual needs, the priority level information can be various forms Information.On this basis, above-mentioned executing subject, can be in response to receiving at least one data inquiry request of terminal transmission According to the priority level that each the priority level information is characterized, these inquiry requests are ranked up, obtain inquiry request sequence Column.Later, for each inquiry request in inquiry request sequence, at least one query statement is successively resolved to.It is basic herein On, it can one or more query statements execution subsequent processing steps corresponding for each inquiry request.
Figure 4, it is seen that increasing compared with the corresponding embodiment of Fig. 2 and storing query result storage to target Position, and update inquiry status information corresponding with data inquiry request the step of, be convenient for user understanding inquiry state and Data storage location.In addition, it is whether legal by verify data inquiry request, illegal data inquiry request can be filtered.
With further reference to Fig. 5, as the realization to method shown in above-mentioned each figure, present disclose provides a kind of data query dresses It sets, the device is corresponding with embodiment of the method shown in Fig. 2, which specifically can be applied in various electronic equipments.
As shown in figure 5, the data query device 500 of the present embodiment includes: resolution unit 501, query unit 502, storage Unit 503 and push unit 504.Wherein, the data query that resolution unit 501 is configured in response to receive terminal transmission is asked It asks, data inquiry request is resolved at least one query statement.Query unit 502 is configured to based at least one inquiry language Query statement in sentence, is inquired in target database, obtains query result.Storage unit 503 is configured to inquire As a result target storage position is arrived in storage.Push unit 504, which is configured to push the position including target storage position to terminal, to be believed The prompt information of breath.
In the present embodiment, resolution unit 501, the query unit 502, storage unit for including in data query device 500 The 503 specific processing with push unit 504 and brought technical effect can be with reference to the step 201- of the corresponding embodiment of Fig. 2 204, details are not described herein.
In some optional implementations of the present embodiment, resolution unit 501 is further configured to: in response to receiving The data inquiry request sent to terminal, determines whether data inquiry request is legal;In response to determining that data inquiry request is legal, Data inquiry request is resolved at least one query statement.
In some optional implementations of the present embodiment, resolution unit 501 is further configured to: in response to receiving The data inquiry request sent to terminal, obtains the classification information of query engine;According to the classification information of query engine, by data Inquiry request resolves at least one query statement.
In some optional implementations of the present embodiment, the device 500 further include: (do not show in figure with new unit Out).Wherein, it is configured to update inquiry status information corresponding with data inquiry request with new unit.
In some optional implementations of the present embodiment, resolution unit 501 is further configured to: in response to receiving At least one data inquiry request sent to terminal, at least one inquiry request, according to the priority level information at least One inquiry request is ranked up, and obtains inquiry request sequence;For the inquiry request in inquiry request sequence, which is looked into Inquiry request analysis is at least one query statement.
In the present embodiment, the data inquiry request that resolution unit can be sent in response to receiving terminal, data are looked into Inquiry request analysis is at least one query statement.On this basis, query unit is based on the inquiry at least one query statement Sentence is inquired in target database, obtains query result.It is deposited finally, storage unit stores query result to target Storage space is set and push unit pushes the prompt information of the location information including target storage position to terminal.To make user It can be by sending the inquiry of request database, and data are exported into target storage position.Compared with prior art, It does not need user and writes query statement, so that it may complete to data query.
Below with reference to Fig. 6, it illustrates the electronic equipment that is suitable for being used to realize embodiment of the disclosure, (example is as shown in figure 1 Server) 600 structural schematic diagram.Electronic equipment shown in Fig. 6 is only an example, should not be to embodiment of the disclosure Function and use scope bring any restrictions.
As shown in fig. 6, electronic equipment 600 includes processing unit (such as central processing unit, graphics processor etc.) 601, Random access storage device can be loaded into according to the program being stored in read-only memory (ROM) 602 or from storage device 608 (RAM) program in 603 and execute various movements appropriate and processing.In RAM 603, it is also stored with the behaviour of electronic equipment 600 Various programs and data needed for making.Processing unit 601, ROM 602 and RAM 603 are connected with each other by bus 604.It is defeated Enter/export (I/O) interface 605 and is also connected to bus 604.
In general, following device can connect to I/O interface 605: including such as touch screen, touch tablet, keyboard, mouse, taking the photograph As the input unit 606 of head, microphone, accelerometer, gyroscope etc.;Including such as liquid crystal display (LCD), loudspeaker, vibration The output device 607 of dynamic device etc.;Storage device 608 including such as tape, hard disk etc.;And communication device 609.Communication device 609, which can permit electronic equipment 600, is wirelessly or non-wirelessly communicated with other equipment to exchange data.Although Fig. 6 shows tool There is the electronic equipment 600 of various devices, it should be understood that being not required for implementing or having all devices shown.It can be with Alternatively implement or have more or fewer devices.Each box shown in Fig. 6 can represent a device, can also root According to needing to represent multiple devices.
Particularly, in accordance with an embodiment of the present disclosure, it may be implemented as computer above with reference to the process of flow chart description Software program.For example, embodiment of the disclosure includes a kind of computer program product comprising be carried on computer-readable medium On computer program, which includes the program code for method shown in execution flow chart.In such reality It applies in example, which can be downloaded and installed from network by communication device 609, or from storage device 608 It is mounted, or is mounted from ROM 602.When the computer program is executed by middle processing unit 601, the reality of the disclosure is executed Apply the above-mentioned function of limiting in the method for example.
It is situated between it should be noted that computer-readable medium described in embodiment of the disclosure can be computer-readable signal Matter or computer readable storage medium either the two any combination.Computer readable storage medium for example can be with System, device or the device of --- but being not limited to --- electricity, magnetic, optical, electromagnetic, infrared ray or semiconductor, or it is any more than Combination.The more specific example of computer readable storage medium can include but is not limited to: have one or more conducting wires Electrical connection, portable computer diskette, hard disk, random access storage device (RAM), read-only memory (ROM), erasable type are programmable Read-only memory (EPROM or flash memory), optical fiber, portable compact disc read-only memory (CD-ROM), light storage device, magnetic are deposited Memory device or above-mentioned any appropriate combination.In embodiment of the disclosure, computer readable storage medium, which can be, appoints What include or the tangible medium of storage program that the program can be commanded execution system, device or device use or and its It is used in combination.And in embodiment of the disclosure, computer-readable signal media may include in a base band or as carrier wave The data-signal that a part is propagated, wherein carrying computer-readable program code.The data-signal of this propagation can be adopted With diversified forms, including but not limited to electromagnetic signal, optical signal or above-mentioned any appropriate combination.Computer-readable signal is situated between Matter can also be that any computer-readable medium other than computer readable storage medium, the computer-readable medium can be sent out It send, propagate or transmits for by the use of instruction execution system, device or device or program in connection.It calculates The program code for including on machine readable medium can transmit with any suitable medium, including but not limited to: electric wire, optical cable, RF Etc. or above-mentioned any appropriate combination.
Above-mentioned computer-readable medium can be included in above-mentioned electronic equipment;It is also possible to individualism, and not It is fitted into the electronic equipment.Above-mentioned computer-readable medium carries one or more program, when said one or more When a program is executed by the electronic equipment, so that the electronic equipment: the data inquiry request in response to receiving terminal transmission, it will Data inquiry request resolves at least one query statement;Based on the query statement at least one query statement, in number of targets According to being inquired in library, query result is obtained;By query result storage to target storage position;It pushes to terminal and is deposited including target The prompt information for the location information that storage space is set.
The calculating of the operation for executing the disclosure can be write with one or more programming languages or combinations thereof Machine program code, described program design language include object oriented program language-such as Java, Smalltalk, C+ +, it further include conventional procedural programming language-such as " C " language or similar programming language.Program code can Fully to execute, partly execute on the user computer on the user computer, be executed as an independent software package, Part executes on the remote computer or executes on a remote computer or server completely on the user computer for part. In situations involving remote computers, remote computer can pass through the network of any kind --- including local area network (LAN) Or wide area network (WAN)-is connected to subscriber computer, or, it may be connected to outer computer (such as utilize Internet service Provider is connected by internet).
Flow chart and block diagram in attached drawing illustrate system, method and the computer of the various embodiments according to the disclosure The architecture, function and operation in the cards of program product.In this regard, each box in flowchart or block diagram can be with A part of a module, program segment or code is represented, a part of the module, program segment or code includes one or more Executable instruction for implementing the specified logical function.It should also be noted that in some implementations as replacements, institute in box The function of mark can also occur in a different order than that indicated in the drawings.For example, two boxes succeedingly indicated are practical On can be basically executed in parallel, they can also be executed in the opposite order sometimes, and this depends on the function involved.Also it wants It is noted that the combination of each box in block diagram and or flow chart and the box in block diagram and or flow chart, Ke Yiyong The dedicated hardware based system of defined functions or operations is executed to realize, or can be referred to specialized hardware and computer The combination of order is realized.
Being described in unit involved in embodiment of the disclosure can be realized by way of software, can also be passed through The mode of hardware is realized.Described unit also can be set in the processor, for example, can be described as: a kind of processor Including resolution unit, query unit, storage unit and push unit.Wherein, the title of these units is not under certain conditions The restriction to the unit itself is constituted, for example, resolution unit is also described as " in response to receiving the data of terminal transmission Data inquiry request is resolved to the unit of at least one query statement by inquiry request ".
Above description is only the preferred embodiment of the disclosure and the explanation to institute's application technology principle.Those skilled in the art Member is it should be appreciated that invention scope involved in the disclosure, however it is not limited to technology made of the specific combination of above-mentioned technical characteristic Scheme, while should also cover in the case where not departing from foregoing invention design, it is carried out by above-mentioned technical characteristic or its equivalent feature Any combination and the other technical solutions formed.Such as features described above has similar function with (but being not limited to) disclosed in the disclosure Can technical characteristic replaced mutually and the technical solution that is formed.

Claims (12)

1. a kind of data query method, comprising:
In response to receiving the data inquiry request of terminal transmission, the data inquiry request is resolved at least one inquiry language Sentence;
Based on the query statement at least one described query statement, is inquired in target database, obtain query result;
By query result storage to target storage position;
It include the prompt information of the location information of the target storage position to terminal push.
2. according to the method described in claim 1, wherein, the data inquiry request in response to receiving terminal transmission will The data inquiry request resolves at least one query statement, comprising:
In response to receiving the data inquiry request of terminal transmission, determine whether the data inquiry request is legal;
It is legal in response to the determination data inquiry request, the data inquiry request is resolved at least one query statement.
3. according to the method described in claim 1, wherein, the data inquiry request in response to receiving terminal transmission will The data inquiry request resolves at least one query statement, comprising:
In response to receiving the data inquiry request of terminal transmission, the classification information of query engine is obtained;
According to the classification information of the query engine, the data inquiry request is resolved at least one query statement.
4. according to the method described in claim 1, including the position of the target storage position to terminal push wherein Before the prompt information of information, the method also includes:
Update inquiry status information corresponding with the data inquiry request.
5. method according to any one of claims 1-4, wherein the data query in response to receiving terminal transmission Request, resolves at least one query statement for the data inquiry request, comprising:
In response to receiving at least one data inquiry request of terminal transmission, at least one inquiry request, according to preferential Level information is ranked up at least one inquiry request, obtains inquiry request sequence;
For the inquiry request in the inquiry request sequence, which is resolved at least one query statement.
6. a kind of data query device, comprising:
Resolution unit is configured in response to receive the data inquiry request of terminal transmission, by the data inquiry request solution Analysis is at least one query statement;
Query unit is configured to carry out in target database based on the query statement at least one described query statement Inquiry, obtains query result;
Storage unit is configured to store the query result to target storage position;
Push unit is configured to push the prompt information of the location information including the target storage position to the terminal.
7. device according to claim 6, wherein the resolution unit is further configured to:
In response to receiving the data inquiry request of terminal transmission, determine whether the data inquiry request is legal;
It is legal in response to the determination data inquiry request, the data inquiry request is resolved at least one query statement.
8. device according to claim 6, wherein the resolution unit is further configured to:
In response to receiving the data inquiry request of terminal transmission, the classification information of query engine is obtained;
According to the classification information of the query engine, the data inquiry request is resolved at least one query statement.
9. device according to claim 6, wherein described device further include:
With new unit, it is configured to update inquiry status information corresponding with the data inquiry request.
10. according to the device any in claim 6-9, wherein the resolution unit is further configured to:
In response to receiving at least one data inquiry request of terminal transmission, at least one inquiry request, according to preferential Level information is ranked up at least one inquiry request, obtains inquiry request sequence;
For the inquiry request in the inquiry request sequence, which is resolved at least one query statement.
11. a kind of server, comprising:
One or more processors;
Storage device is stored thereon with one or more programs,
When one or more of programs are executed by one or more of processors, so that one or more of processors are real Now such as method as claimed in any one of claims 1 to 5.
12. a kind of computer-readable medium, is stored thereon with computer program, wherein real when described program is executed by processor Now such as method as claimed in any one of claims 1 to 5.
CN201910053418.1A 2019-01-21 2019-01-21 Data query method and apparatus Pending CN109710859A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910053418.1A CN109710859A (en) 2019-01-21 2019-01-21 Data query method and apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910053418.1A CN109710859A (en) 2019-01-21 2019-01-21 Data query method and apparatus

Publications (1)

Publication Number Publication Date
CN109710859A true CN109710859A (en) 2019-05-03

Family

ID=66262460

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910053418.1A Pending CN109710859A (en) 2019-01-21 2019-01-21 Data query method and apparatus

Country Status (1)

Country Link
CN (1) CN109710859A (en)

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111209326A (en) * 2020-01-02 2020-05-29 广州虎牙科技有限公司 Data query method and device, electronic equipment and storage medium
CN111581356A (en) * 2020-05-15 2020-08-25 北京易数科技有限公司 User behavior path analysis method and device
CN112037857A (en) * 2020-08-13 2020-12-04 中国科学院微生物研究所 Bacterial strain genome annotation query method, device, electronic equipment and storage medium
CN112307061A (en) * 2019-10-31 2021-02-02 北京京东尚科信息技术有限公司 Method and device for querying data
CN112527830A (en) * 2020-12-24 2021-03-19 平安普惠企业管理有限公司 Data query method, device, equipment and storage medium
CN112765460A (en) * 2021-01-08 2021-05-07 北京字跳网络技术有限公司 Conference information query method, device, storage medium, terminal device and server
CN113407562A (en) * 2021-06-04 2021-09-17 北京金山云网络技术有限公司 Communication method and device of distributed database system
CN114138867A (en) * 2021-12-02 2022-03-04 杭州复杂美科技有限公司 Blockchain multiple query method, computer equipment and storage medium
CN115617837A (en) * 2022-11-08 2023-01-17 中国银行股份有限公司 Data query method and device
CN116628012A (en) * 2023-05-26 2023-08-22 中国银行股份有限公司 Data query method, device, equipment and storage medium

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060271510A1 (en) * 2005-05-25 2006-11-30 Terracotta, Inc. Database Caching and Invalidation using Database Provided Facilities for Query Dependency Analysis
CN105205085A (en) * 2014-06-30 2015-12-30 中兴通讯股份有限公司 Multi-dimensional analysis method and device for mass data
CN106484875A (en) * 2016-10-13 2017-03-08 广州视源电子科技股份有限公司 MOLAP-based data processing method and device
CN106777108A (en) * 2016-12-15 2017-05-31 贵州电网有限责任公司电力科学研究院 A kind of data query method and apparatus based on mixing storage architecture
CN108509637A (en) * 2018-04-10 2018-09-07 口碑(上海)信息技术有限公司 Tables of data relation query method and device
CN108563736A (en) * 2018-04-10 2018-09-21 口碑(上海)信息技术有限公司 The method and device of data is inquired based on data characteristics
CN109062883A (en) * 2018-07-18 2018-12-21 平安科技(深圳)有限公司 Tables of data dynamic deriving method, device, computer equipment and storage medium

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060271510A1 (en) * 2005-05-25 2006-11-30 Terracotta, Inc. Database Caching and Invalidation using Database Provided Facilities for Query Dependency Analysis
CN105205085A (en) * 2014-06-30 2015-12-30 中兴通讯股份有限公司 Multi-dimensional analysis method and device for mass data
CN106484875A (en) * 2016-10-13 2017-03-08 广州视源电子科技股份有限公司 MOLAP-based data processing method and device
CN106777108A (en) * 2016-12-15 2017-05-31 贵州电网有限责任公司电力科学研究院 A kind of data query method and apparatus based on mixing storage architecture
CN108509637A (en) * 2018-04-10 2018-09-07 口碑(上海)信息技术有限公司 Tables of data relation query method and device
CN108563736A (en) * 2018-04-10 2018-09-21 口碑(上海)信息技术有限公司 The method and device of data is inquired based on data characteristics
CN109062883A (en) * 2018-07-18 2018-12-21 平安科技(深圳)有限公司 Tables of data dynamic deriving method, device, computer equipment and storage medium

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112307061A (en) * 2019-10-31 2021-02-02 北京京东尚科信息技术有限公司 Method and device for querying data
CN112307061B (en) * 2019-10-31 2025-02-21 北京京东尚科信息技术有限公司 Method and device for querying data
CN111209326A (en) * 2020-01-02 2020-05-29 广州虎牙科技有限公司 Data query method and device, electronic equipment and storage medium
CN111581356A (en) * 2020-05-15 2020-08-25 北京易数科技有限公司 User behavior path analysis method and device
CN112037857B (en) * 2020-08-13 2024-03-26 中国科学院微生物研究所 Strain genome annotation query method and device, electronic equipment and storage medium
CN112037857A (en) * 2020-08-13 2020-12-04 中国科学院微生物研究所 Bacterial strain genome annotation query method, device, electronic equipment and storage medium
CN112527830A (en) * 2020-12-24 2021-03-19 平安普惠企业管理有限公司 Data query method, device, equipment and storage medium
CN112765460A (en) * 2021-01-08 2021-05-07 北京字跳网络技术有限公司 Conference information query method, device, storage medium, terminal device and server
US12511338B2 (en) 2021-01-08 2025-12-30 Beijing Zitiao Network Technology Co., Ltd. Conference information query method and apparatus, storage medium, terminal device, and server
CN113407562A (en) * 2021-06-04 2021-09-17 北京金山云网络技术有限公司 Communication method and device of distributed database system
CN114138867A (en) * 2021-12-02 2022-03-04 杭州复杂美科技有限公司 Blockchain multiple query method, computer equipment and storage medium
CN115617837A (en) * 2022-11-08 2023-01-17 中国银行股份有限公司 Data query method and device
CN116628012A (en) * 2023-05-26 2023-08-22 中国银行股份有限公司 Data query method, device, equipment and storage medium

Similar Documents

Publication Publication Date Title
CN109710859A (en) Data query method and apparatus
JP2021103506A (en) Method and device for generating information
CN109697075A (en) File updating method, system and device
CN113468342B (en) Knowledge graph-based data model construction method, device, equipment and medium
CN111552715B (en) User query method and device
CN109388626A (en) Method and apparatus for being numbered to traffic assignments
CN110222775A (en) Image processing method, device, electronic equipment and computer readable storage medium
US11809429B2 (en) Method for processing model parameters, and apparatus
CN108921712A (en) Data processing method, device, medium and electronic equipment
CN109992719B (en) Method and apparatus for determining push priority information
CN109656799A (en) Test method and device
CN111813685B (en) Automatic test method and device
CN109255035A (en) Method and apparatus for constructing knowledge mapping
CN109409419A (en) Method and apparatus for handling data
CN108733720A (en) The on-line testing method and check system of the SQL query of multiple database type
JP2022541929A (en) Method and apparatus for issuing smart contracts
CN115034175A (en) Table data processing method, device, terminal and storage medium
CN111338944A (en) Remote Procedure Call (RPC) interface test method, device, medium and equipment
CN112579447A (en) Browser testing method and device
CN110019242A (en) Processing method, device and system for tables of data
US10585678B2 (en) Insertion of custom activities in an orchestrated application suite
CN109218041A (en) Request processing method and device for server system
CN111241137B (en) Data processing method, device, electronic equipment and storage medium
CN111787041B (en) Method and device for processing data
CN108959642A (en) Method and apparatus for information to be written

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: 20190503