CN108427688A - Data query method and apparatus - Google Patents
Data query method and apparatus Download PDFInfo
- Publication number
- CN108427688A CN108427688A CN201710081643.7A CN201710081643A CN108427688A CN 108427688 A CN108427688 A CN 108427688A CN 201710081643 A CN201710081643 A CN 201710081643A CN 108427688 A CN108427688 A CN 108427688A
- Authority
- CN
- China
- Prior art keywords
- data query
- data
- requirements
- function
- query function
- 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.)
- Granted
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/24—Querying
- G06F16/245—Query processing
- G06F16/2457—Query processing with adaptation to user needs
- G06F16/24573—Query processing with adaptation to user needs using data annotations, e.g. user-defined metadata
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/24—Querying
- G06F16/245—Query processing
- G06F16/2453—Query optimisation
- G06F16/24534—Query rewriting; Transformation
- G06F16/24547—Optimisations to support specific applications; Extensibility of optimisers
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/40—Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
- H04N21/47—End-user applications
- H04N21/472—End-user interface for requesting content, additional data or services; End-user interface for interacting with content, e.g. for content reservation or setting reminders, for requesting event notification, for manipulating displayed content
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/60—Network structure or processes for video distribution between server and client or between remote clients; Control signalling between clients, server and network components; Transmission of management data between server and client, e.g. sending from server to client commands for recording incoming content stream; Communication details between server and client
- H04N21/61—Network physical structure; Signal processing
- H04N21/6106—Network physical structure; Signal processing specially adapted to the downstream path of the transmission network
- H04N21/6125—Network physical structure; Signal processing specially adapted to the downstream path of the transmission network involving transmission via Internet
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/60—Network structure or processes for video distribution between server and client or between remote clients; Control signalling between clients, server and network components; Transmission of management data between server and client, e.g. sending from server to client commands for recording incoming content stream; Communication details between server and client
- H04N21/63—Control signaling related to video distribution between client, server and network components; Network processes for video distribution between server and clients or between remote clients, e.g. transmitting basic layer and enhancement layers over different transmission paths, setting up a peer-to-peer communication via Internet between remote STB's; Communication protocols; Addressing
- H04N21/643—Communication protocols
- H04N21/64322—IP
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Signal Processing (AREA)
- Multimedia (AREA)
- Databases & Information Systems (AREA)
- Data Mining & Analysis (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Physics & Mathematics (AREA)
- Computational Linguistics (AREA)
- Library & Information Science (AREA)
- Human Computer Interaction (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
The embodiment of the invention discloses a kind of data query method and apparatus, the range for growth data inquiry.Present invention method includes:Receive the data query requirements of input;According to the data query requirements, data query function is determined;According to the information for the description data query function of being carried in the metadata to prestore, metadata corresponding with the data query function is obtained;The data query function is configured in the preset database according to the corresponding metadata;Data query is executed using the data query function in the database.In this way, after filtering out the metadata of needs according to data query requirements, by metadata configurations data query function, which can perform new data query, extends the range of the data query of system.
Description
Technical field
The present invention relates to field of information processing more particularly to a kind of data query method and apparatus.
Background technology
Existing data query method, usually system are pre-established with the functional device for executing the data query needed,
User carries out corresponding data query using the functional device pre-established.This data query range for causing system executable
It is smaller, the more demands of user cannot be met.
For example, in the fields IPTV, the data query type that IPTV system provides often presets completion, and user is only
The data query function that pre-establish of IPTV system can be used to be inquired, if user wants to inquire other information, and the IPTV systems
System corresponding data query function is not provided, then user by cannot to think inquiry information inquire.
Invention content
An embodiment of the present invention provides a kind of data query method and apparatus, the range for growth data inquiry.
In order to solve the above-mentioned technical problem, an embodiment of the present invention provides following technical schemes:
A kind of data query method, including:
Receive the data query requirements of input;
According to the data query requirements, data query function is determined;
According to the information for the description data query function of being carried in the metadata to prestore, obtain and the data query function
Corresponding metadata;
The data query function is configured in the preset database according to the corresponding metadata;
Data query is executed using the data query function in the presetting database.
Optionally, described to determine data query function according to the data query requirements, including:
Keyword is extracted from the data query requirements;
Multiple data query function choosing-items for waiting for selection are provided according to the keyword;
Selection instruction is received, the selection instruction from the multiple data query function choosing-item for waiting for selection for selecting
At least one data query function choosing-item;
At least one data query function choosing-item that the selection instruction selects is determined as the data query function.
Optionally, after the data query requirements for receiving input, the method further includes:
The content of the data query requirements is parsed, analysis result is obtained;
According to the analysis result, classify to the data query requirements, data query requirements correspond to described in every class
At least one data query function;
The input number of data query requirements described in every class is counted respectively;
According to the data query requirements, data query function is determined, including:
Obtain the input number of data query requirements described in every class;
The input number is more than to the corresponding at least one data query function of data query requirements of predetermined threshold value, really
It is set to the data query function.
Optionally, it is described according to the corresponding metadata configure in the preset database the data query function it
Before, the method further includes:
It determines and executes the basic data that the data query function needs;
Judge in the presetting database whether to include the basic data;
If not including the basic data in the presetting database, the basic data is acquired;
The basic data of acquisition is stored in the presetting database, alternatively, to the basic data of acquisition
It is stored in after being filtered in the presetting database.
Optionally, the data query requirements are multiple, and corresponding data are carried in each data query requirements
The significance level information of query demand is stored with the execution frequency letter of each data query requirements in the presetting database
Breath, it is described that data query is executed using the data query function in the database, including:
According to the execution frequency information of the significance level information of the data query requirements and the data query requirements, really
The Query priority of fixed each data query requirements;
It is searched respectively and each data query requirements in the presetting database according to the Query priority
The data matched;
If within a preset period of time, do not find with the matched data of the data query requirements, then stop execute with
The corresponding data query of the data query requirements, and export inquiry status information.
In order to solve the above-mentioned technical problem, the embodiment of the present invention additionally provides following technical scheme:
A kind of data query arrangement, including:
Receiving unit, the data query requirements for receiving input;
Determination unit, for according to the data query requirements, determining data query function;
Metadata acquiring unit is obtained for the information according to the description data query function of being carried in the metadata to prestore
Take metadata corresponding with the data query function;
Dispensing unit, for configuring the data query function in the preset database according to the corresponding metadata;
Execution unit, for executing data query using the data query function in the presetting database.
Optionally, the determination unit, including:
Extraction module, for extracting keyword from the data query requirements;
Module is provided, for providing multiple data query function choosing-items for waiting for selection according to the keyword;
Receiving module, for receiving selection instruction, the selection instruction is used for from the multiple data query for waiting for selection
At least one data query function choosing-item is selected in function choosing-item;
First determining module, at least one data query function choosing-item for selecting the selection instruction are determined as institute
State data query function.
Optionally, described device further includes:
Resolution unit parses for the content to the data query requirements, obtains analysis result;
Taxon, for according to the analysis result, classifying to the data query requirements, data described in every class
Query demand corresponds at least one data query function;
Counting unit counts respectively for the input number to data query requirements described in every class;
The determination unit, including:
Number acquisition module, the input number for obtaining data query requirements described in every class;
Second determining module, the data query requirements corresponding at least one for the input number to be more than to predetermined threshold value
A data query function is determined as the data query function.
Optionally, described device further includes:
Data determination unit, for determining the basic data for executing the data query function and needing;
Judging unit, for judging in the presetting database whether to include the basic data;
Collecting unit acquires the basic number if for not including the basic data in the presetting database
According to;
Storage unit, for the basic data of acquisition to be stored in the presetting database, alternatively, to acquisition
The basic data is stored in after being filtered in the presetting database.
Optionally, the data query requirements are multiple, and corresponding data are carried in each data query requirements
The significance level information of query demand is stored with the execution frequency letter of each data query requirements in the presetting database
Breath, the execution unit, including:
Priority Determination module is used for the significance level information according to the data query requirements and the data query need
The execution frequency information asked determines the Query priority of each data query requirements;
Searching module, for being searched respectively and each number in the presetting database according to the Query priority
According to the matched data of query demand;
Output module, if within a preset period of time, do not find with the matched data of the data query requirements,
Then stop executing data query corresponding with the data query requirements, and exports inquiry status information.
As can be seen from the above technical solutions, the embodiment of the present invention has the following advantages:
After the data query requirements for receiving input, according to the data query requirements, data query function is determined.Then,
According to the information for the description data query function of being carried in preset metadata, member corresponding with the data query function is obtained
Data.To configure the data query function in the preset database according to the corresponding metadata, then described default
Data query is executed using the data query function in database.In this way, filtering out the member of needs according to data query requirements
After data, you can the data query function of going out executable inquiry operation according to the metadata configurations uses the data query function
I.e. executable data query operation, which is the inexecutable operation of system before configuration data query function,
After by metadata configurations data query function, which can perform new data query, extend system
Data query range.
Description of the drawings
Fig. 1 is a kind of method flow diagram for data query method that one embodiment of the invention provides;
Fig. 2 is a kind of method flow diagram for data query method that another embodiment of the present invention provides;
Fig. 3 is a kind of structural schematic diagram for data query arrangement that one embodiment of the invention provides;
Fig. 4 is a kind of structural schematic diagram for data query arrangement that another embodiment of the present invention provides.
Specific implementation mode
An embodiment of the present invention provides a kind of data query method and apparatus, the range for growth data inquiry.
Fig. 1 is a kind of method flow diagram of data query method provided in an embodiment of the present invention, and refering to fig. 1, the present invention is real
The data query method for applying example includes:
Step 101:Receive the data query requirements of input.
Step 102:According to data query requirements, data query function is determined.
Step 103:According to the information for the description data query function of being carried in the metadata to prestore, acquisition and data query
The corresponding metadata of function.
Step 104:According to corresponding metadata configuration data query function in the preset database.
Step 105:Data query function is used to execute data query in the preset database.
Optionally, according to data query requirements, data query function is determined, including:
Keyword is extracted from data query requirements;
Multiple data query function choosing-items for waiting for selection are provided according to keyword;
Selection instruction is received, selection instruction is at least one for being selected from multiple data query function choosing-items for waiting for selection
Data query function choosing-item;
At least one data query function choosing-item that selection instruction selects is determined as data query function.
Optionally, after the data query requirements for receiving input, the method for the embodiment of the present invention further includes:
The content of data query requirements is parsed, analysis result is obtained;
According to analysis result, classify to data query requirements, at least one data are corresponded to per class data query requirements
Query function;
The input number of every class data query requirements is counted respectively;
According to data query requirements, data query function is determined, including:
Obtain the input number per class data query requirements;
Data query requirements corresponding at least one data query function of the number more than predetermined threshold value will be inputted, is determined as
Data query function.
Optionally, before according to corresponding metadata in the preset database configuration data query function, the present invention is implemented
Example method further include:
It determines and executes the basic data that data query function needs;
Judge in presetting database whether to include basic data;
If not including basic data in presetting database, basic data is acquired;
In the preset database by the basic data storage of acquisition, alternatively, being deposited after being filtered to the basic data of acquisition
Storage is in the preset database.
Optionally, data query requirements are multiple, and corresponding data query requirements are carried in each data query requirements
Significance level information, the execution frequency information of each data query requirements is stored in presetting database, is adopted in the database
Data query is executed with data query function, including:
According to the execution frequency information of the significance level information of data query requirements and data query requirements, determine per number
According to the Query priority of query demand;
It is searched and the matched data of each data query requirements respectively in the preset database according to Query priority;
If within a preset period of time, do not find with the matched data of data query requirements, then stop execute and data
The corresponding data query of query demand, and export inquiry status information.
In conclusion after receiving the data query requirements inputted, according to data query requirements, data query function is determined.
Then, it according to the information for the description data query function of being carried in preset metadata, obtains corresponding with data query function
Metadata.To according to corresponding metadata configuration data query function in the preset database, then adopt in the preset database
Data query is executed with data query function.In this way, after filtering out the metadata of needs according to data query requirements, you can according to
The metadata configurations go out the data query function of executable inquiry operation, use the i.e. executable data query of the data query function
Operation, which is the inexecutable operation of system before configuration data query function, to be matched by metadata
After setting data query function, which can perform new data query, extend the range of the data query of system.
Fig. 2 is a kind of method flow diagram of data query method provided in an embodiment of the present invention, referring to Fig.2, the present invention is real
The data query method for applying example includes:
Step 201:Receive the data query requirements of input.
Equipment receives data query requirements input by user, which can indicate that user needs to inquire
The information of data.
After equipment obtains data query requirements input by user, you can execute corresponding behaviour according to the data query requirements
Make.And the data query requirements contain the focus that user inquires data, to which equipment is obtained according to the data query requirements
The focus of user.
Wherein execute equipment equipment such as can be computer of the method for the embodiment of the present invention.
For example, user inputs the data query to be inquired to the interface of IPTV (Interactive Internet TV) task processing equipment
Demand " daily audience ratings " inquires relevant task to be executed by the task processing equipment with daily audience ratings.
Step 202:According to data query requirements, data query function is determined.
After equipment obtains data query requirements, you can determine that user needs the data used according to the data query requirements
Query function, the data query function are data query functions to be configured currently in the system of equipment there is no setting.Really
After making data query function to be configured, the system of equipment subsequently can just configure the data query function, to use the number
Corresponding inquiry operation is executed according to query function.
After data query function is determined, configuration operation is just executed, setting should not on device systems before configuration
Data query function, so as to the function of thin device.
Wherein, according to data query requirements, there are many concrete methods of realizing for determining data query function, enumerates below
Two.
Example one:
Step A1:Keyword is extracted from data query requirements.
Data query requirements are the relevant information of user's data to be checked, in the information of the data query requirements, including one
A little keywords, these keywords can be that staff inputs or sets to equipment in advance, to which equipment can be according in advance
The keyword of setting is matched in data query requirements input by user, determines the keyword being matched to, to realize
Keyword is always extracted from data query requirements.
Step A2:Multiple data query function choosing-items for waiting for selection are provided according to keyword.
The keyword that step A1 is extracted can be corresponding with data query function choosing-item, to which equipment can provide a user and be somebody's turn to do
The corresponding data query function choosing-item of keyword, so that user selects.
For example, equipment is after getting data query requirements input by user " daily audience ratings ", equipment extracts key
Word " audience ratings ", to provide a user multiple data query function choosing-items for waiting for selection according to keyword " audience ratings ":" Beijing
Satellite TV's audience ratings inquiry ", " prime-time ratings inquiry " etc..
Step A3:Receive selection instruction.
Selection instruction from multiple data query function choosing-items for waiting for selection for selecting at least one data query function
Option.
User see equipment provide it is multiple after the data query function choosing-item of selection, by mouse click etc. modes to
Equipment input receives instruction, to select multiple option, selects the data query function of user's needs.
Step A4:At least one data query function choosing-item that selection instruction selects is determined as data query function.
The data query option that equipment is selected according to selection instruction determines the corresponding data query to be configured of the selection
Function.
For example, user selects the option of addition " inquiry of Beijing TV audience ratings ", after addition, IPTV system determines " north
Capital satellite TV audience ratings inquiry " is data query function to be configured.
Example two
Wherein, after the data query requirements for receiving input, the method for the embodiment of the present invention further includes:
Step B1:The content of data query requirements is parsed, analysis result is obtained;
Data query requirements are the relevant information of user's data to be checked, include more in the information of the data query requirements
Kind information, to which equipment can parse the content of the data query requirements, for example, being carried out at participle to data query requirements
Reason, obtains the phrase for constituting the data query requirements.
Step B2:According to analysis result, classify to data query requirements.
At least one data query function is corresponded to per class data query requirements.
The analysis result obtained according to above-mentioned steps can classify to data query requirements, such as according to data query
The phrase that demand includes is classified, to determine which data query function the data query requirements belong to.
Step B3:The input number of every class data query requirements is counted respectively;
After determining which data query function data query requirements belong to, you can assigned to the data query function
Data query requirements are counted.
To, according to data query requirements, determine data query function, including:
Step B4:Obtain the input number per class data query requirements.
After being counted to data query requirements, the input number of the data query requirements of every one kind is obtained, wherein.It is defeated
Indegree more multilist shows that user can more pay close attention to the data query.
Step B5:Data query requirements corresponding at least one data query work(of the number more than predetermined threshold value will be inputted
Can, it is determined as data query function.
Judge whether the input number of data query function is more than pre-set threshold value, if the input number of the data query function
More than pre-set threshold value, then show that user relatively pays close attention to the data query function, to which equipment can determine that the data query function
For data query function to be configured.
For example, the data query requirements often inputted according to user, system automatic identification and some functions are added.For example,
Client often inputs Beijing TV, but now there is no the related datas of Beijing TV in systems, and client does not also select
Addition is selected, when the channel of clients' input Beijing TV being waited to reach a threshold value, equipment adds this function automatically.
It is appreciated that in the embodiment that the present invention has, some basic functions of meeting default setting in the system of equipment, than
Such as viewing number hourly, watch duration, if client's input and these relevant data query requirements of inquiry, equipment to
The corresponding query result of user's auto-returned.
Step 203:According to the information for the description data query function of being carried in the metadata to prestore, acquisition and data query
The corresponding metadata of function.
Metadata is prestored in equipment, which has the relevant information of data query function.According to metadata
The data query function that configurable step 202 is determined.Because different metadata corresponds to different data query functions, pre-
When the metadata deposited corresponds to multiple and different data query functions, the description data query function of being carried according to metadata is needed
Information determines metadata corresponding with data query function to be configured.
Step 204:According to corresponding metadata configuration data query function in the preset database.
Meta-data preservation the relevant information of data query function, so as to prepare for automatic business processing.Filtering out needs
After the metadata wanted, you can according to these metadata configuration data query function in the database, to pass through the data query work(
Data query task corresponding with data query requirements input by user can be executed.
Wherein, which can be the system for executing data query function, for example, IPTV service system.Data
Query function is the function module of executable data query.
Optionally, before according to corresponding metadata in the preset database configuration data query function, the present invention is implemented
Example method further include:It determines and executes the basic data that data query function needs;Judge in presetting database whether to include base
Plinth data;If not including basic data in presetting database, basic data is acquired;The basic data of acquisition is stored in pre-
If in database, alternatively, being stored in the preset database after being filtered to the basic data of acquisition.In this way, configuration data is looked into
After asking function, you can carry out the execution of inquiry data using the basic data in presetting database.
About the configuration of data query function, specific method can be as described below:
1) auto-configuration data processing module.
According to the metadata of system, the processing module of configuration data query function.
For example, data query function to be configured includes inquiring the function of Beijing TV audience ratings, protected according in metadata
The information deposited, data, the audience ratings which needs data filtering module to filter out Beijing TV are analyzed.
2) basic data memory module is built automatically.
According to the metadata of system, need to store the basic data that data query function needs, these data need according to
Structure as defined in metadata builds an interim data storage cell;If existing system can meet these these numbers
According to storage, then can be multiplexed these storage units, if cannot be satisfied, create new storage unit.
3) auto-configuration data acquisition module.
It according to the metadata of system, needs to acquire the data that new function needs, if the data area of existing system acquisition
Including these data, then be multiplexed, if conditions are not met, then needing to configure acquisition system, it is ensured that can collect this part number
According to.
Step 205:Data query function is used to execute data query in the preset database.
After configuring data query function, you can use data query function execution and step in the preset database
The 201 corresponding data query of data query requirements, thus to user's returned data query result.
The method of inventive embodiments can be used for multiple fields, such as can be applied to the fields IPTV, and so as to aspect, user holds
The operation of row IPTV.
In IPTV service, the system of the equipment of IPTV service includes real-time system and non real-time system, non real-time system
Refer to processing time relatively long system, for example processing in one day is primary or the system several times of processing in one day;Real-time system
Refer to that data are acquired from client, showing to data processing, to the page, the time is no more than a few minutes or several seconds
System.
The system of the equipment of IPTV service can also include pseudo- real-time system, pseudo- real-time system be between in real-time system and non-
System between real-time system, pseudo- real-time system be usually complete data processing in 10 minutes, 30 minutes or 1 hours be
System.
The method of the embodiment of the present invention can be in above-mentioned real-time system, non real-time system and pseudo- real-time system, this
Inventive embodiments are not specifically limited this.
Wherein, the method for the embodiment of the present invention can be particularly used in pseudo- real-time system, so as to shorten pseudo- real-time system
Processing time, the process performance of lifting means.In this way, compared to real-time system, it is possible to reduce the function of equipment and the generation of cost
Valence.Compared to non real-time system, either hardware requirement or software development, pseudo- real-time system is one in non real-time system
A promotion.
When executing the method for the embodiment of the present invention, it is sometimes desirable to consider specific usage scenario to carry out the excellent of method
Change, such as considers the correct interruption of the priority and task of executing for task.
Especially in the processing in real time of the puppet of IPTV, due to the limitation of processing time, need to consider appointing for data query function
The correct interruption of the priority and task of business.At this point, can establish task scheduling system with to task priority and task just
It really interrupts and is handled.
To which in the embodiment that the present invention has, data query requirements are multiple, are carried in each data query requirements
The significance level information of corresponding data query requirements is stored with the execution frequency of each data query requirements in presetting database
Information,
Data query corresponding with data query requirements is executed in the preset database, including:
Step C1:According to the execution frequency information of the significance level information of data query requirements and data query requirements, really
The Query priority of fixed each data query requirements.
Because for pseudo- real-time system, may can not deal all indexs within the unit interval, it is all this
In require a priority, preferential high person, priority processing.
Wherein it is determined that the Query priority of each data query requirements can specifically be found out with use priority formula:
Priority=significance level information × execution frequency information.
Wherein, significance level information preservation in the metadata, configures when system initialization, can also be repaiied in the later stage
Change.Execute frequency information be then client in practical operation to the usage frequency of new function.
Step C2:It is searched and the matched number of each data query requirements respectively in the preset database according to Query priority
According to;
Step C3:If within a preset period of time, do not find with the matched data of data query requirements, then stop executing
Data query corresponding with data query requirements, and export inquiry status information.
Pseudo- real-time system requires that this data processing must be completed within the regular hour, otherwise can influence next time
Data processing task, so in data processing, if task processing time is overtime, it is necessary to terminate current data automatically
Query function.
Automatically the processing terminated cannot influence later processing, and what all terminations here referred to is not that simple stopping is worked as
Pre-treatment, but saving scene information is wanted, addition processing daily record needs to be merged into next especially for certain cumulative datas
In secondary task processing, it cannot reprocess, can not miss.So the method for the embodiment of the present invention is stopping execution and data
After the corresponding data query of query demand, output inquiry status information is needed, which, which records, there are termination data
Field data when query function.In this way next time execute data query function when, you can according to the inquiry status information with
The preceding data query functional status point once stopped starting to execute data query function.
The method that the embodiment of the present invention is used in the pseudo- real-time system of IPTV service, by obtaining data input by user
Query demand can be with auto-focusing user's focus of attention, then according to the most concerned problem of priority priority processing client.
Meet requirement of the user to real-time property in certain condition, the cost paid but is the cost of non real-time system.
In conclusion after receiving the data query requirements inputted, according to data query requirements, data query function is determined.
Then, it according to the information for the description data query function of being carried in preset metadata, obtains corresponding with data query function
Metadata.To according to corresponding metadata configuration data query function in the preset database, then use number in the database
Data query is executed according to query function.In this way, after filtering out the metadata of needs according to data query requirements, you can according to this yuan
Data configuration goes out the data query function of executable inquiry operation, is grasped using the i.e. executable data query of the data query function
Make, which is the inexecutable operation of system before configuration data query function, to pass through metadata configurations
After data query function, which can perform new data query, extend the range of the data query of system.
Fig. 3 is a kind of structural schematic diagram of data query arrangement provided in an embodiment of the present invention, and refering to Fig. 3, the present invention is real
The data query arrangement for applying example includes:
Receiving unit 301, the data query requirements for receiving input;
Determination unit 302, for according to data query requirements, determining data query function;
Metadata acquiring unit 303, for the information according to the description data query function of being carried in the metadata that prestores,
Obtain metadata corresponding with data query function;
Dispensing unit 304, for according to corresponding metadata configuration data query function in the preset database;
Execution unit 305, for using data query function to execute data query in the preset database.
The embodiment of the present invention provides a kind of structural schematic diagram of data query arrangement, as shown in figure 4, including:
Receiving unit 401, the data query requirements for receiving input;
Determination unit 402, for according to data query requirements, determining data query function;
Metadata acquiring unit 403, for the information according to the description data query function of being carried in the metadata that prestores,
Obtain metadata corresponding with data query function;
Dispensing unit 404, for according to corresponding metadata configuration data query function in the preset database;
Execution unit 405, for using data query function to execute data query in the preset database.
Wherein it is determined that unit 402, including:
Extraction module 406, for extracting keyword from data query requirements;
Module 407 is provided, for providing multiple data query function choosing-items for waiting for selection according to keyword;
Receiving module 408, for receiving selection instruction, selection instruction is used for from multiple data query function choosings for waiting for selection
At least one data query function choosing-item is selected in;
First determining module 409, at least one data query function choosing-item for selecting selection instruction are determined as counting
According to query function.
Optionally, the device of the embodiment of the present invention further includes:
Resolution unit 410 parses for the content to data query requirements, obtains analysis result;
Taxon 411, for according to analysis result, classifying to data query requirements, per class data query requirements
Corresponding at least one data query function;
Counting unit 412 counts respectively for the input number to every class data query requirements;
Determination unit 402, including:
Number acquisition module 413, the input number for obtaining every class data query requirements;
Second determining module 414 is more than the data query requirements corresponding at least one of predetermined threshold value for that will input number
A data query function, is determined as data query function.
Optionally, the device of the embodiment of the present invention further includes:
Data determination unit 415, for determining the basic data for executing data query function and needing;
Judging unit 416, for judging in presetting database whether to include basic data;
If collecting unit 417 acquires basic data for not including basic data in presetting database;
Storage unit 418, the basic data for that will acquire store in the preset database, alternatively, to the basis of acquisition
Data store in the preset database after being filtered.
Optionally, data query requirements are multiple, and corresponding data query requirements are carried in each data query requirements
Significance level information, the execution frequency information of each data query requirements is stored in presetting database,
Execution unit 405, including:
Priority Determination module 419, for according to the significance level information of data query requirements and data query requirements
Frequency information is executed, determines the Query priority of each data query requirements;
Searching module 420, for being searched and each data query need respectively in the preset database according to Query priority
Seek matched data;
Output module 421, if within a preset period of time, do not find with the matched data of data query requirements,
Then stop executing data query corresponding with data query requirements, and exports inquiry status information.
In conclusion after receiving unit 301 receives the data query requirements inputted, determination unit 302 is according to data query
Demand determines data query function.Then, metadata acquiring unit 303 is according to the description data carried in preset metadata
The information of query function obtains metadata corresponding with data query function.To which dispensing unit 304 is according to corresponding first number
According to configuration data query function in the preset database, execution unit 305 uses data query function in the preset database again
Execute data query.In this way, after filtering out the metadata of needs according to data query requirements, you can gone out according to the metadata configurations
The data query function of executable inquiry operation, using the i.e. executable data query operation of the data query function, which looks into
It is the inexecutable operation of system before configuration data query function to ask operation, to pass through metadata configurations data query function
Afterwards, which can perform new data query, extend the range of the data query of system.
It is apparent to those skilled in the art that for convenience and simplicity of description, the system of foregoing description,
The specific work process of device and unit, can refer to corresponding processes in the foregoing method embodiment, and details are not described herein.
In several embodiments provided herein, it should be understood that disclosed system, device and method can be with
It realizes by another way.For example, the apparatus embodiments described above are merely exemplary, for example, the unit
It divides, only a kind of division of logic function, formula that in actual implementation, there may be another division manner, such as multiple units or component
It can be combined or can be integrated into another system, or some features can be ignored or not executed.Another point, it is shown or
The mutual coupling, direct-coupling or communication connection discussed can be the indirect coupling by some interfaces, device or unit
It closes or communicates to connect, can be electrical, machinery or other forms.
The unit illustrated as separating component may or may not be physically separated, aobvious as unit
The component shown may or may not be physical unit, you can be located at a place, or may be distributed over multiple
In network element.Some or all of unit therein can be selected according to the actual needs to realize the mesh of this embodiment scheme
's.
In addition, each functional unit in each embodiment of the present invention can be integrated in a processing unit, it can also
It is that each unit physically exists alone, it can also be during two or more units be integrated in one unit.Above-mentioned integrated list
The form that hardware had both may be used in member is realized, can also be realized in the form of SFU software functional unit.
If the integrated unit is realized in the form of SFU software functional unit and sells or use as independent product
When, it can be stored in a computer read/write memory medium.Based on this understanding, technical scheme of the present invention is substantially
The all or part of the part that contributes to existing technology or the technical solution can be in the form of software products in other words
It embodies, which is stored in a storage medium, including some instructions are used so that a computer
Equipment (can be personal computer, server or the network equipment etc.) executes the complete of each embodiment the method for the present invention
Portion or part steps.And storage medium above-mentioned includes:USB flash disk, mobile hard disk, read-only memory (ROM, Read-Only
Memory), random access memory (RAM, Random Access Memory), magnetic disc or CD etc. are various can store journey
The medium of sequence code.
The above, the above embodiments are merely illustrative of the technical solutions of the present invention, rather than its limitations;Although with reference to before
Stating embodiment, invention is explained in detail, it will be understood by those of ordinary skill in the art that:It still can be to preceding
The technical solution recorded in each embodiment is stated to modify or equivalent replacement of some of the technical features;And these
Modification or replacement, the spirit and scope for various embodiments of the present invention technical solution that it does not separate the essence of the corresponding technical solution.
Claims (10)
1. a kind of data query method, which is characterized in that including:
Receive the data query requirements of input;
According to the data query requirements, data query function is determined;
According to the information for the description data query function of being carried in the metadata to prestore, obtain corresponding with the data query function
Metadata;
The data query function is configured in the preset database according to the corresponding metadata;
Data query is executed using the data query function in the presetting database.
2. according to the method described in claim 1, it is characterized in that, described according to the data query requirements, determine that data are looked into
Function is ask, including:
Keyword is extracted from the data query requirements;
Multiple data query function choosing-items for waiting for selection are provided according to the keyword;
Selection instruction is received, the selection instruction from the multiple data query function choosing-item for waiting for selection for selecting at least
One data query function choosing-item;
At least one data query function choosing-item that the selection instruction selects is determined as the data query function.
3. according to the method described in claim 1, it is characterized in that, it is described receive input data query requirements after, it is described
Method further includes:
The content of the data query requirements is parsed, analysis result is obtained;
According to the analysis result, classify to the data query requirements, data query requirements correspond at least described in every class
One data query function;
The input number of data query requirements described in every class is counted respectively;
According to the data query requirements, data query function is determined, including:
Obtain the input number of data query requirements described in every class;
The input number is more than to the corresponding at least one data query function of data query requirements of predetermined threshold value, is determined as
The data query function.
4. according to the method described in claim 1, it is characterized in that, it is described according to the corresponding metadata in presetting database
Before the middle configuration data query function, the method further includes:
It determines and executes the basic data that the data query function needs;
Judge in the presetting database whether to include the basic data;
If not including the basic data in the presetting database, the basic data is acquired;
The basic data of acquisition is stored in the presetting database, alternatively, the basic data to acquisition carries out
It is stored in after filtering in the presetting database.
5. method according to any one of claims 1 to 4, which is characterized in that the data query requirements be it is multiple, each
The significance level information of corresponding data query requirements is carried in the data query requirements, is stored in the presetting database
There is the execution frequency information of each data query requirements, it is described to be held in the database using the data query function
Row data query, including:
According to the execution frequency information of the significance level information of the data query requirements and the data query requirements, determine every
The Query priority of a data query requirements;
According to the Query priority, lookup and each data query requirements are matched respectively in the presetting database
Data;
If within a preset period of time, do not find with the matched data of the data query requirements, then stop execute with it is described
The corresponding data query of data query requirements, and export inquiry status information.
6. a kind of data query arrangement, which is characterized in that including:
Receiving unit, the data query requirements for receiving input;
Determination unit, for according to the data query requirements, determining data query function;
Metadata acquiring unit, for the information according to the description data query function of being carried in the metadata that prestores, obtain with
The corresponding metadata of the data query function;
Dispensing unit, for configuring the data query function in the preset database according to the corresponding metadata;
Execution unit, for executing data query using the data query function in the database.
7. device according to claim 6, which is characterized in that
The determination unit, including:
Extraction module, for extracting keyword from the data query requirements;
Module is provided, for providing multiple data query function choosing-items for waiting for selection according to the keyword;
Receiving module, for receiving selection instruction, the selection instruction is used for from the multiple data query function of waiting for selection
At least one data query function choosing-item is selected in option;
First determining module, at least one data query function choosing-item for selecting the selection instruction are determined as the number
According to query function.
8. device according to claim 6, which is characterized in that
Described device further includes:
Resolution unit parses for the content to the data query requirements, obtains analysis result;
Taxon, for according to the analysis result, classifying to the data query requirements, data query described in every class
Demand corresponds at least one data query function;
Counting unit counts respectively for the input number to data query requirements described in every class;
The determination unit, including:
Number acquisition module, the input number for obtaining data query requirements described in every class;
Second determining module, the corresponding at least one number of data query requirements for the input number to be more than to predetermined threshold value
According to query function, it is determined as the data query function.
9. device according to claim 6, which is characterized in that
Described device further includes:
Data determination unit, for determining the basic data for executing the data query function and needing;
Judging unit, for judging in the presetting database whether to include the basic data;
Collecting unit acquires the basic data if for not including the basic data in the presetting database;
Storage unit, for the basic data of acquisition to be stored in the presetting database, alternatively, to described in acquisition
Basic data is stored in after being filtered in the presetting database.
10. according to claim 6 to 9 any one of them device, which is characterized in that the data query requirements be it is multiple, often
The significance level information of corresponding data query requirements is carried in a data query requirements, is deposited in the presetting database
Contain the execution frequency information of each data query requirements, the execution unit, including:
Priority Determination module, for according to the significance level information of the data query requirements and the data query requirements
Frequency information is executed, determines the Query priority of each data query requirements;
Searching module is looked into for being searched respectively in the presetting database according to the Query priority with each data
The matched data of inquiry demand;
Output module, if within a preset period of time, do not find with the matched data of the data query requirements, then stop
Data query corresponding with the data query requirements is only executed, and exports inquiry status information.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710081643.7A CN108427688B (en) | 2017-02-15 | 2017-02-15 | Data query method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710081643.7A CN108427688B (en) | 2017-02-15 | 2017-02-15 | Data query method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN108427688A true CN108427688A (en) | 2018-08-21 |
CN108427688B CN108427688B (en) | 2022-01-28 |
Family
ID=63155467
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201710081643.7A Active CN108427688B (en) | 2017-02-15 | 2017-02-15 | Data query method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108427688B (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20230023392A1 (en) * | 2020-06-30 | 2023-01-26 | The Nielsen Company (Us), Llc | Methods and apparatus to estimate the second frequency moment for computer-monitored media accesses |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101079056A (en) * | 2007-02-06 | 2007-11-28 | 腾讯科技(深圳)有限公司 | Retrieving method and system |
CN101799811A (en) * | 2009-02-06 | 2010-08-11 | 北京蓝通易和科技有限公司 | Certificate information inquiring method and inquiring system |
CN103678619A (en) * | 2013-12-17 | 2014-03-26 | 北京国双科技有限公司 | Database index processing method and device |
CN106156088A (en) * | 2015-04-01 | 2016-11-23 | 阿里巴巴集团控股有限公司 | A kind of index data processing method, data query method and device |
US20170024474A1 (en) * | 2010-01-14 | 2017-01-26 | Excalibur Ip, Llc | Search engine recency using content preview |
-
2017
- 2017-02-15 CN CN201710081643.7A patent/CN108427688B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101079056A (en) * | 2007-02-06 | 2007-11-28 | 腾讯科技(深圳)有限公司 | Retrieving method and system |
CN101799811A (en) * | 2009-02-06 | 2010-08-11 | 北京蓝通易和科技有限公司 | Certificate information inquiring method and inquiring system |
US20170024474A1 (en) * | 2010-01-14 | 2017-01-26 | Excalibur Ip, Llc | Search engine recency using content preview |
CN103678619A (en) * | 2013-12-17 | 2014-03-26 | 北京国双科技有限公司 | Database index processing method and device |
CN106156088A (en) * | 2015-04-01 | 2016-11-23 | 阿里巴巴集团控股有限公司 | A kind of index data processing method, data query method and device |
Non-Patent Citations (1)
Title |
---|
王齐等: "改进的基于文本节点的XML文档查询方法", 《广西师范大学学报(自然科学版)》 * |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20230023392A1 (en) * | 2020-06-30 | 2023-01-26 | The Nielsen Company (Us), Llc | Methods and apparatus to estimate the second frequency moment for computer-monitored media accesses |
US11687967B2 (en) * | 2020-06-30 | 2023-06-27 | The Nielsen Company (Us), Llc | Methods and apparatus to estimate the second frequency moment for computer-monitored media accesses |
Also Published As
Publication number | Publication date |
---|---|
CN108427688B (en) | 2022-01-28 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN1278266C (en) | System and method for mining work flow | |
CN100517293C (en) | Method for extracting content, content extraction server based on RSS and apparatus for managing the same and system for providing standby screen of mobile communication terminal using the same | |
EP2378442A1 (en) | System and method for effectively implementing a personal channel for interactive television | |
CN106487664B (en) | Information recommendation method and device and mobile terminal | |
CN111327955B (en) | User portrait based on-demand method, storage medium and smart television | |
CN105025318A (en) | Feedback method and device for abnormal log information of application program | |
CN102982273B (en) | Information handling system and information processing method | |
CN102750629B (en) | Schedule association method and device | |
CN109725995B (en) | Method, device and equipment for executing data extraction task and readable storage medium | |
CN100433650C (en) | Method and system for synchronizing network administration data in network optimizing system | |
CN101656623A (en) | Software installing method, sever and system | |
JP2019049839A (en) | Data analysis system and data analysis method and data analysis program | |
CN105227358B (en) | The setting method and system of network type | |
CN103995807A (en) | Massive data query and secondary processing method based on Web architecture | |
CN104462096A (en) | Public opinion monitoring and analysis method and device | |
CN108574718B (en) | Cloud host creation method and device | |
CN107609172B (en) | Cross-system multi-dimensional data retrieval processing method and device | |
CN106371856A (en) | Menu statistical method and user terminal and application backstage terminal | |
CN108959458B (en) | Data generation and use method, system, medium and computer device | |
CN113010310B (en) | Method, device and server for processing job data | |
CN108427688A (en) | Data query method and apparatus | |
US20090106412A1 (en) | Network system, network management device and management method thereof | |
CN105224394B (en) | A kind of classification method and device of application program | |
CN101379490B (en) | Storage profile generation for network-connected portable storage devices | |
US20130290245A1 (en) | Database history management method and system thereof |
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 | ||
CB02 | Change of applicant information |
Address after: 100080 No. 401, 4th Floor, Haitai Building, 229 North Fourth Ring Road, Haidian District, Beijing Applicant after: Beijing Guoshuang Technology Co.,Ltd. Address before: 100086 Cuigong Hotel, 76 Zhichun Road, Shuangyushu District, Haidian District, Beijing Applicant before: Beijing Guoshuang Technology Co.,Ltd. |
|
CB02 | Change of applicant information | ||
GR01 | Patent grant | ||
GR01 | Patent grant |