[go: up one dir, main page]

CN101206654B - Database query system and method with intelligent query capability - Google Patents

Database query system and method with intelligent query capability Download PDF

Info

Publication number
CN101206654B
CN101206654B CN2006101707922A CN200610170792A CN101206654B CN 101206654 B CN101206654 B CN 101206654B CN 2006101707922 A CN2006101707922 A CN 2006101707922A CN 200610170792 A CN200610170792 A CN 200610170792A CN 101206654 B CN101206654 B CN 101206654B
Authority
CN
China
Prior art keywords
query
database
statements
intelligent
objects
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.)
Expired - Fee Related
Application number
CN2006101707922A
Other languages
Chinese (zh)
Other versions
CN101206654A (en
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.)
Chen Zhaojin
Cong Rong
Guo Hongjie
Li Juan
Wang Huichao
Original Assignee
Inventec Corp
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 Inventec Corp filed Critical Inventec Corp
Priority to CN2006101707922A priority Critical patent/CN101206654B/en
Publication of CN101206654A publication Critical patent/CN101206654A/en
Application granted granted Critical
Publication of CN101206654B publication Critical patent/CN101206654B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

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

Abstract

The invention discloses a database query system and a database query method with intelligent query capability. The system disclosed by the invention comprises the following components: the system comprises an intelligent memory base, a database and an analysis query module. After the user inputs the query objects, the intelligent memory library is used for searching whether corresponding query sentences exist or not, if so, the database is queried by the query sentences, if not, the query objects are delivered to the analysis query module to generate a plurality of query sentences, the database is queried to calculate corresponding query combination scores, and the query sentences with lower query cost are found and recorded in the intelligent memory library. Then, if the user queries with the same query object again, the query statement can be automatically selected for querying data, so that the query efficiency of the database is reduced by using the query statement with poor efficiency to query the database.

Description

具智能查询能力的数据库查询系统与方法Database query system and method with intelligent query capability

技术领域technical field

本发明涉及一种数据库查询系统与方法,尤其涉及一种具智能查询能力,可自动产生输入的查询对象所对应的查询组合的数据库查询系统与方法。The invention relates to a database query system and method, in particular to a database query system and method with intelligent query capability and capable of automatically generating query combinations corresponding to input query objects.

背景技术Background technique

随着计算机运用普及化,资料数据的记录渐渐由记录于纸本文件转为记录于电子媒介(或文件),各类数据可记录于这些电子媒介(或文件)而汇整为数据库。数据库里最常使用的功能为查询数据,使用者可通过下达查询指令,例如以SQL指令查询,而由数据库撷取相关联的数据。举例来说,将问卷调查数据,包括受测者的性别、年龄、嗜好、收入、以及每周看电影次数等储存于数据库中。使用者若想知道年龄层大于20岁的电影市场,可通过下达简单的查询指令得知,例如:Select Movie_Times_Week From Survey--_Inf where age>20,而使用者还可通过较复杂的查询指令及运算,得知上述年龄层的潜在电影市场总值,使用者可下达例如:Select SUM(ICOME)From Survey_Inf where age>20以得知年龄层在20岁以上的受测者收入总值,以及下达例如:SelectSUM(Movie_Times_Week)From Survey_Inf where age>20得知年龄层在20岁以上的受测者每周观看电影的总次数,并将查询道的20岁以上的受测者收入总值减掉每周观看电影的总次数所花费的金额,便可得到上述的潜在电影市场总值。With the popularization of computer use, the recording of data and data has gradually changed from being recorded in paper documents to being recorded in electronic media (or files). Various data can be recorded in these electronic media (or files) and compiled into a database. The most commonly used function in the database is querying data. Users can retrieve associated data from the database by issuing query commands, such as querying with SQL commands. For example, the questionnaire survey data, including the sex, age, hobbies, income, and weekly movie times of the testees, etc. are stored in the database. If the user wants to know the movie market whose age group is older than 20, he can know it by issuing a simple query command, for example: Select Movie_Times_Week From Survey--_Inf where age>20, and the user can also use more complex query commands and Calculate, to know the total value of the potential film market of the above age group, the user can issue an example: Select SUM (ICOME) From Survey_Inf where age > 20 to know the total income of the subjects whose age group is over 20 years old, and issue For example: SelectSUM(Movie_Times_Week) From Survey_Inf where age > 20 Know the total number of times that the subjects over the age of 20 watch movies every week, and subtract the total income of the subjects over the age of 20 from the query channel The total value of the potential movie market mentioned above can be obtained from the amount spent on the total number of times the movie is watched in a week.

然而,欲将数据库的功用发挥的淋漓尽致,往往取决于下达的查询指令的良莠,而查询指令的良莠取决于使用者对数据库(例如字段意义)的了解,以及下达的查询指令的复杂度,例如以一个较复杂的SQL指令撷取数据可能较以多个较简单的SQL指令撷取数据费时,因此较复杂的SQL就可被视为质量较差的查询指令。由此可见,人为操作因素可能会迫使在搜集与管理数据库的数据的效能大打折扣,因此需要一种可独立于人为操作的数据库查询系统与方法,避免与改善上述的缺失。However, to fully utilize the functions of the database often depends on the quality of the query commands issued, and the quality of the query commands depends on the user's understanding of the database (such as the meaning of fields) and the complexity of the query commands issued For example, retrieving data with one more complex SQL command may take more time than retrieving data with multiple simpler SQL commands, so a more complex SQL can be regarded as a poor quality query command. It can be seen that human operation factors may force the performance of collecting and managing database data to be greatly reduced. Therefore, a database query system and method independent of human operation is needed to avoid and improve the above-mentioned defects.

发明内容Contents of the invention

本发明所要解决的技术问题在于输入查询对象后可自动产生对应的查询语句,用以在数据库查询数据。The technical problem to be solved by the present invention is to automatically generate a corresponding query statement after inputting a query object to query data in a database.

为实现上述目的,本发明通过系统与方法两方面达成,本发明所揭露的系统,包括有:一个智能记忆库,用以储存多个查询对象及其对应的查询语句;一个数据库,用以储存数据供使用者查询;以及一个分析查询模块,用以产生这些查询对象对应的多个对象组合,并依据一个查询算法产生对应的查询语句,以查询此数据库从而输出一个结果集。其中,上述的分析查询模块更计算这些查询语句对应的查询组合分数,并记录最小的查询组合分数对应的查询语句于智能记忆库,及将由数据库的输出,汇集成一个结果集。In order to achieve the above object, the present invention is achieved through two aspects of system and method. The system disclosed in the present invention includes: an intelligent memory bank for storing multiple query objects and their corresponding query statements; a database for storing The data is for users to query; and an analysis and query module is used to generate multiple object combinations corresponding to these query objects, and generate corresponding query statements according to a query algorithm to query the database and output a result set. Wherein, the above-mentioned analysis and query module further calculates the query combination scores corresponding to these query statements, and records the query statements corresponding to the smallest query combination scores in the intelligent memory, and collects the output from the database into a result set.

本发明所揭露的具智能查询能力的数据库查询方法,包括有下列步骤:首先输入至少一查询对象,以查询对应的至少一查询语句;之后,若判断有对应的查询语句,则依据这些查询语句查询数据库,以输出一个结果集;然后,若判断不具有对应的查询语句,则依据这些查询对象产生多个对象组合,并依据一个查询算法产生这些对象组合对应的查询语句用以查询数据库;接着依据此数据库的输出计算这些查询语句对应的多个查询组合分数;最后,找出最小的查询组合分数,并记录此查询组合分数对应的查询语句,及输出此查询语句对应的结果集。The database query method with intelligent query capability disclosed by the present invention includes the following steps: firstly input at least one query object to query at least one corresponding query statement; afterward, if it is determined that there is a corresponding query statement, then according to these query statements Query the database to output a result set; then, if it is judged that there is no corresponding query statement, generate multiple object combinations based on these query objects, and generate query statements corresponding to these object combinations according to a query algorithm to query the database; then According to the output of the database, multiple query combination scores corresponding to these query statements are calculated; finally, the smallest query combination score is found, and the query statement corresponding to the query combination score is recorded, and the result set corresponding to the query statement is output.

由上述系统与方法可知,本发明通过产生查询对象对应的查询语句,并计算及记录这些查询语句对应的查询代价较小的一个查询语句,而在往后以相同的查询对象查询时,得以自动取出对应的查询语句来查询数据,以避免人为操作数据库时,下达较差效益或错误的查询语句而降低数据库系统的使用效益。As can be seen from the above system and method, the present invention generates query statements corresponding to query objects, and calculates and records a query statement corresponding to these query statements with a relatively small query cost, so that when querying with the same query object in the future, it can automatically Take out the corresponding query statement to query the data, so as to avoid reducing the efficiency of the database system by issuing poor efficiency or wrong query statements when man-operating the database.

有关本发明的详细特征与实作,兹配合图示在实施方式中详细说明如下,其内容足以使本领域的技术人员了解本发明的技术内容并据以实施,且根据本说明书所揭露的内容及图式,任何本领域技术人员可轻易地理解本发明相关的目的及优点。Regarding the detailed features and implementation of the present invention, it will be described in detail in the implementation mode with reference to the drawings as follows, the content of which is sufficient for those skilled in the art to understand the technical content of the present invention and implement it accordingly, and according to the content disclosed in this specification With the accompanying drawings, any person skilled in the art can easily understand the related objects and advantages of the present invention.

附图说明Description of drawings

图1为本发明实施例所提的数据库查询系统示意图;Fig. 1 is the schematic diagram of the database inquiry system that the embodiment of the present invention proposes;

图2为本发明实施例所提的数据库查询方法流程图。FIG. 2 is a flow chart of the database query method proposed in the embodiment of the present invention.

其中,附图标记:Among them, reference signs:

110:智能记忆库110: Intelligent Memory Bank

120:数据库120: database

130:分析查询模块130: Analysis query module

132:查询演算模块132: Query calculation module

134:结果值比对模块134: Result value comparison module

具体实施方式Detailed ways

为让本发明的上述及其它目的、特征和优点能更显而易懂,下文特举出一实施例,并配合所附图式,作详细说明如下。In order to make the above and other objects, features and advantages of the present invention more comprehensible, an embodiment will be exemplified below and described in detail in conjunction with the accompanying drawings.

图1为本发明实施例所提的数据库查询系统示意图。请参照图1,本实施例的数据库查询系统(以后简称系统)包括一个智能记忆库110用来储存输入的查询对象以及这些查询对象对应的查询语句;一个数据库120,用来储存数据以供使用者查询;一个分析查询模块130,用来产生查询对象对应的对象组合,以及依据一个算法来产生对应的查询语句,并用这些查询语句在数据库120查询出一个结果集。另外,分析查询模块130会依据每一查询语句查询所需的时间以及回传的结果集的成员个数计算出对应的查询组合分数。这些查询组合分数代表使用这些查询语句查询数据库120的代价。分析查询模块130会找出这些查询组合分数中最小值(在本实施例中,有较小的查询组合分数代表对应的查询语句可以用较短的时间查询出较精确的数据),并将这个最小的查询组合分数所对应的查询对象及查询语句储存于智能记忆库当中,并将查询到的结果集输出予使用者。FIG. 1 is a schematic diagram of a database query system proposed in an embodiment of the present invention. Please refer to Fig. 1, the database query system (hereinafter referred to as the system) of the present embodiment includes an intelligent memory bank 110 for storing input query objects and query statements corresponding to these query objects; a database 120 for storing data for use or query; an analysis query module 130 is used to generate the object combination corresponding to the query object, and generate corresponding query statements according to an algorithm, and use these query statements to query a result set in the database 120 . In addition, the query analysis module 130 calculates the corresponding query combination score according to the time required for each query statement and the number of members of the returned result set. These query combination scores represent the cost of querying the database 120 using these query statements. The analysis query module 130 will find out the minimum value in these query combination scores (in this embodiment, a smaller query combination score represents that the corresponding query statement can query more accurate data in a shorter time), and this The query object and query statement corresponding to the smallest query combination score are stored in the intelligent memory, and the query result set is output to the user.

接续上一段落,上述的分析查询模块130中还包括一个查询演算模块132以及一个比对模块134。查询演算模块132存放计算查询对象对应的多种查询语句的算法,查询演算模块132可通过此算法依据查询对象的关系产生一些对象组合,以进一步依据这些对象组合产生对应的查询语句。当分析查询模块130产生数个查询语句,并以这些查询语句查询数据库120后得到查询结果,分析查询模块130会将这些查询结果汇集成一个结果集。此时,比对模块134则会依据这些结果集的成员个数以及产生这些结果及所需时间产生对应的查询组合分数,并更进一步判断出最小的一个查询组合分数及其对应的查询语句,用以将这个查询语句记录于智能记忆库110。当使用者下次输入相同的查询对象时,系统便不需再次产生对应的查询语句,而可直接由智能记忆库提取查询语句来查询数据。Continuing from the previous paragraph, the above analysis and query module 130 also includes a query calculation module 132 and a comparison module 134 . The query calculation module 132 stores algorithms for calculating various query statements corresponding to query objects. The query calculation module 132 can use this algorithm to generate some object combinations according to the relationship between query objects, and further generate corresponding query statements based on these object combinations. When the analysis and query module 130 generates several query statements and uses these query statements to query the database 120 to obtain query results, the analysis and query module 130 collects these query results into a result set. At this time, the comparison module 134 will generate corresponding query combination scores based on the number of members of these result sets and the time required to generate these results, and further determine the smallest query combination score and its corresponding query statement. It is used to record the query statement in the intelligent memory bank 110 . When the user inputs the same query object next time, the system does not need to generate the corresponding query statement again, but can directly retrieve the query statement from the intelligent memory bank to query data.

附带一提,本系统的智能记忆库110可以例如是一个硬盘或是一个闪存等可用以储存查询对象与对应的查询语句的媒介,而查询语句在本实施例中,例如是一种结构化查询语言指令(Structured Query Language,SQL),任何本领域的技术人员,当可依本实施例的教示加以修改,在此不限制其范围。Incidentally, the intelligent memory bank 110 of this system can be, for example, a hard disk or a flash memory, etc., which can be used to store query objects and corresponding query statements. In this embodiment, the query statement is, for example, a structured query Language instructions (Structured Query Language, SQL), anyone skilled in the art, should be modified according to the teachings of this embodiment, and its scope is not limited here.

图2为本发明实施例所提的数据库查询方法流程图。请参照图2,本实施例的数据库查询方法包括如下步骤:首先,输入至少一个查询对象(步骤210),这些查询对象例如是使用者欲下达的选取对象以及范围,而不是例如SQL等数据库查询指令;此时,系统会判断是否具有这些查询对象对应的查询语句,查询语句例如为SQL或其它用以查询数据库的查询指令,若判断具有对应的数个查询语句,则依据这些查询语句查询该数据库,以输出一结果集(步骤220);若判断不具对应的查询语句,则依据这些查询对象产生数个对象组合,并依据一个查询算法产生这些对象组合对应的查询语句用以查询数据库(步骤230);然后,依据数据库输出的数据来计算这些查询语句对应的查询组合分数(步骤240);最后,找出最小的查询组合分数,并记录此查询组合分数对应的查询语句,及输出查询语句对应的结果集(步骤250)。FIG. 2 is a flow chart of the database query method proposed in the embodiment of the present invention. Please refer to Fig. 2, the database query method of the present embodiment includes the following steps: first, input at least one query object (step 210), these query objects are for example the selection object and range that the user wants to issue, rather than database queries such as SQL Instructions; at this time, the system will judge whether there are query statements corresponding to these query objects. The query statements are, for example, SQL or other query instructions for querying the database. database to output a result set (step 220); if it is judged that there is no corresponding query statement, then generate several object combinations according to these query objects, and generate query statements corresponding to these object combinations according to a query algorithm for querying the database (step 230); then, according to the data output by the database, calculate the query combination scores corresponding to these query statements (step 240); finally, find out the minimum query combination scores, and record the query statements corresponding to the query combination scores, and output the query statements The corresponding result set (step 250).

在本实施例中的查询算法为依据输入至少一个查询对象与数据库字段的关系产生对象组合及其对应的查询语句,其包括步骤如下:首先寻找系统的数据库是否包含输入的查询对象;若判断完全不包含这些查询对象,则输出一个错误信息,例如:数据库不包括您欲寻找的数据,请再次输入。若判断包含至少一个查询对象,则依据这些查询对象在数据库的数个表格的的关联性产生对象组合的排列,例如输入A、B、C等三个查询对象据关联性的表格个数各自为5个表格、1个表格、1个表格,此时对象组合例如为ABC,代表依关联性高低查询,先查询A对象相关的信息,再查询B对象,之后再查询C对象;最后,依据这些对象组合产生对应的查询语句。The query algorithm in the present embodiment is based on the relationship between inputting at least one query object and the database field to generate object combinations and corresponding query statements. It includes the following steps: first find whether the database of the system contains the input query object; If these query objects are not included, an error message will be output, for example: the database does not contain the data you are looking for, please enter again. If it is determined that at least one query object is included, then the arrangement of the object combination is generated according to the relevance of these query objects in several tables of the database. There are 5 tables, 1 table, and 1 table. At this time, the object combination is, for example, ABC, which means querying according to the level of relevance. First query the information related to the A object, then query the B object, and then query the C object; finally, based on these Object composition produces corresponding query statements.

承上述,系统分别以产生的各个查询语句自动查询数据库,并将由数据库搜寻到的结果汇集为各个查询语句对应的结果集,结果集包含的字段例如查询对象字段、查询语句字段、所需时间字段、结果成员字段等,用以清楚表示使用者查询的项目、系统产生的数个查询语句、搜寻数据库所需时间、以及由数据库搜寻到的数据。另外,系统更会计算出在步骤240提及的查询组合分数。下达查询语句的质量取决于查询时间以及找出的数据多少,一般而言,使用者希望以越短的时间找出精确的数据,而当下达的查询语句越精确,所找到的结果成员的个数当然越少。举例来说,在商品数据库中欲寻找茶类饮品的售价信息,若单以饮品作为收询的资料,则找出的结果成员个数太过繁多,甚至可能搜寻到碳酸饮料的售价数据。若以茶类饮品、宝特瓶包装、以及销售地点作为查询项目,则虽然找到信息较精确,然而却增加搜寻数据库的时间。查询组合分数就是用来代表以一个查询语句查询数据库的质量,其计算方式为将结果集的结果成员个数加上查询数据库所耗费的时间加总。每一个查询语句均会有对应的查询组合分数,在本实施例中较小的查询组合分数对应的查询语句的质量越高,而较大的查询组合分数所对应的查询语句的质量越低。系统的分析查询模块里的比对模块会选出最低查询组合分数所对应的查询语句作为较佳的查询语句,而记录于智能记忆库。Based on the above, the system automatically queries the database with each generated query statement, and collects the results searched from the database into a result set corresponding to each query statement. The result set contains fields such as query object field, query statement field, and required time field , result member fields, etc., are used to clearly indicate the items the user queries, several query statements generated by the system, the time required to search the database, and the data searched by the database. In addition, the system further calculates the query combination score mentioned in step 240 . The quality of the issued query statement depends on the query time and the amount of data found. Generally speaking, the user hopes to find accurate data in the shortest possible time, and when the query statement issued is more accurate, the individual value of the found result members will be higher. Of course the number is less. For example, if you want to find the selling price information of tea drinks in the product database, if you only use drinks as the query data, you will find too many members in the result, and you may even search for the selling price data of carbonated drinks . If tea drinks, PET bottle packaging, and sales locations are used as query items, although the information found is more accurate, the time for searching the database is increased. The query combination score is used to represent the quality of querying the database with a query statement, and its calculation method is the sum of the number of result members in the result set and the time spent querying the database. Each query statement has a corresponding query combination score. In this embodiment, the quality of the query statement corresponding to the smaller query combination score is higher, while the quality of the query statement corresponding to the larger query combination score is lower. The comparison module in the analysis and query module of the system will select the query statement corresponding to the lowest query combination score as a better query statement, and record it in the intelligent memory bank.

综上所述,本发明因采用智能记忆库储存具较佳查询质量的查询语句,以及通过分析查询模块自动产生查询对象对应的数个查询语句而输入数据库查询及判断具较佳查询质量的查询语句,进而加以储存,而至少有以下优点:In summary, the present invention uses an intelligent memory bank to store query statements with better query quality, and automatically generates several query statements corresponding to query objects through the analysis query module to input database queries and judge queries with better query quality Statements, and then stored, and at least the following advantages:

(1)使用者仅需输入查询项目即可自动产生查询语言。(1) The user only needs to input query items to automatically generate query language.

(2)不需对数据库的表格或字段作深入了解,即可进行操作。(2) Operations can be performed without an in-depth understanding of the tables or fields of the database.

(3)系统自动产生具较高查询质量的查询语句,避免使用较差效益的查询语句查询数据库而降低数据库的查询效益。(3) The system automatically generates query sentences with high query quality, avoiding the use of query sentences with poor efficiency to query the database and reduce the query efficiency of the database.

当然本发明还可有其它多种实施例,在不背离本发明精神及其实质的情况下,熟悉本领域的普通技术人员当可根据本发明做出各种相应的改变和变形,但这些相应的改变和变形都应属于本发明所附的权利要求的保护范围。Of course, the present invention can also have other various embodiments. Without departing from the spirit and essence of the present invention, those skilled in the art can make various corresponding changes and deformations according to the present invention, but these corresponding All changes and deformations should belong to the protection scope of the appended claims of the present invention.

Claims (8)

1.一种具智能查询能力的数据库查询系统,适用于自动产生输入的至少一查询对象所对应的至少一查询语句用以查询数据,其特征在于,该数据库查询系统包括:1. A database query system with intelligent query capability, suitable for automatically generating at least one query statement corresponding to at least one query object of input to query data, characterized in that the database query system includes: 一智能记忆库,用以储存该些查询对象及其对应的该些查询语句;An intelligent memory bank, used to store the query objects and the corresponding query statements; 一数据库,用以储存数据供使用者查询;以及a database for storing data for users to query; and 一分析查询模块,用以产生该些查询对象对应的数个对象组合,并依据一查询算法产生对应的该些查询语句,以查询该数据库而输出一结果集;An analysis and query module, used to generate several object combinations corresponding to the query objects, and generate the corresponding query statements according to a query algorithm, to query the database and output a result set; 该分析查询模块还计算该些查询语句对应的多个查询组合分数,并记录最小的该些查询组合分数对应的查询语句于该智能记忆库,及输出该结果集。The analysis query module also calculates multiple query combination scores corresponding to the query statements, records the query statement corresponding to the smallest query combination scores in the intelligent memory, and outputs the result set. 2.根据权利要求1所述的具智能查询能力的数据库查询系统,其特征在于,该分析查询模块还包括:2. The database query system with intelligent query capability according to claim 1, wherein the analysis query module also includes: 一查询演算模块,用以依据该些查询对象的关系产生该多个对象组合,及产生该些对象组合对应的该些查询语句;以及A query calculation module, used to generate the plurality of object combinations according to the relationship of the query objects, and generate the query statements corresponding to the object combinations; and 一比对模块,用以判断出具最小些该查询组合分数对应的查询语句。A comparison module, used to determine and issue the query statement corresponding to the minimum query combination score. 3.根据权利要求1所述的具智能查询能力的数据库查询系统,其特征在于,该智能记忆库为一硬盘或一闪存。3. The database query system with intelligent query capability according to claim 1, wherein the intelligent memory bank is a hard disk or a flash memory. 4.根据权利要求1所述的具智能查询能力的数据库查询系统,其特征在于,该些查询语句为一结构化查询语言指令。4. The database query system with intelligent query capability according to claim 1, wherein the query statements are structured query language instructions. 5.一种具智能查询能力的数据库查询方法,适用于自动产生输入的至少一查询对象所对应的至少一查询语句以用于在一数据库查询数据,其特征在于,该数据库查询方法包括以下步骤:5. A database query method with intelligent query capability, suitable for automatically generating at least one query statement corresponding to at least one query object of input for querying data in a database, characterized in that the database query method includes the following steps : 输入至少一查询对象;input at least one query object; 判断具有对应的该些查询语句,则依据该些查询语句查询该数据库,以输出一结果集;Judging that there are corresponding query statements, querying the database according to the query statements to output a result set; 判断不具有对应的该些查询语句,则依据该查询对象产生多个对象组合,并依据一查询算法产生该些对象组合对应的查询语句用以查询该数据库;If it is judged that there are no corresponding query statements, multiple object combinations are generated according to the query object, and query statements corresponding to the object combinations are generated according to a query algorithm to query the database; 依据该数据库的输出计算该些查询语句对应的一查询组合分数;以及calculating a query combination score corresponding to the query statements according to the output of the database; and 找出最小的该查询组合分数,并记录该些查询组合分数对应的查询语句,及输出该些查询语句对应的该结果集。Find the smallest query combination score, record the query statements corresponding to the query combination scores, and output the result set corresponding to the query statements. 6.根据权利要求5所述的具智能查询能力的数据库查询方法,其特征在于,该查询算法包括以下步骤:6. The database query method with intelligent query capability according to claim 5, wherein the query algorithm comprises the following steps: 寻找该数据库是否包含输入的该些查询对象;Find whether the database contains the input query objects; 判断完全不包含该些查询对象,则输出一错误信息;If it is judged that these query objects are not included at all, an error message is output; 判断包含至少一该些查询对象,则依据该些查询对象在该数据库的数个表格的关联性产生该些对象组合的排列;以及judging that at least one of the query objects is included, generating an arrangement of combinations of the objects according to the relevance of the query objects in several tables of the database; and 产生该些对象组合对应的该些查询语句。The query statements corresponding to the object combinations are generated. 7.根据权利要求5所述的具智能查询能力的数据库查询方法,其特征在于,该些查询组合分数为该结果集的结果成员的个数以及查询时间的加总。7. The database query method with intelligent query capability according to claim 5, wherein the query combination scores are the sum of the number of result members of the result set and the query time. 8.根据权利要求5所述的具智能查询能力的数据库查询方法,其特征在于,该结果集的字段包括一查询对象字段、一查询语句字段、一所需时间字段、一结果成员字段。8. The database query method with intelligent query capability according to claim 5, wherein the fields of the result set include a query object field, a query statement field, a required time field, and a result member field.
CN2006101707922A 2006-12-22 2006-12-22 Database query system and method with intelligent query capability Expired - Fee Related CN101206654B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2006101707922A CN101206654B (en) 2006-12-22 2006-12-22 Database query system and method with intelligent query capability

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2006101707922A CN101206654B (en) 2006-12-22 2006-12-22 Database query system and method with intelligent query capability

Publications (2)

Publication Number Publication Date
CN101206654A CN101206654A (en) 2008-06-25
CN101206654B true CN101206654B (en) 2010-04-14

Family

ID=39566862

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2006101707922A Expired - Fee Related CN101206654B (en) 2006-12-22 2006-12-22 Database query system and method with intelligent query capability

Country Status (1)

Country Link
CN (1) CN101206654B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101819569A (en) * 2009-02-27 2010-09-01 中兴通讯股份有限公司 Expert system for worksheet preprocessing and worksheet preprocessing method
CN102479223B (en) * 2010-11-25 2014-06-04 中国移动通信集团浙江有限公司 Data query method and system

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5924089A (en) * 1996-09-03 1999-07-13 International Business Machines Corporation Natural language translation of an SQL query
CN1484174A (en) * 2002-09-21 2004-03-24 鸿富锦精密工业(深圳)有限公司 System and method for dynamically generating general query statements
CN1619534A (en) * 2003-11-20 2005-05-25 鸿富锦精密工业(深圳)有限公司 Product catalog intelligent search system and method
CN1691013A (en) * 2004-04-29 2005-11-02 Nec软件有限公司 Structured Natural Language Query and Knowledge Systems
CN1881208A (en) * 2005-06-14 2006-12-20 联想(北京)有限公司 Construction method for dynamic structured query language statement

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5924089A (en) * 1996-09-03 1999-07-13 International Business Machines Corporation Natural language translation of an SQL query
CN1484174A (en) * 2002-09-21 2004-03-24 鸿富锦精密工业(深圳)有限公司 System and method for dynamically generating general query statements
CN1619534A (en) * 2003-11-20 2005-05-25 鸿富锦精密工业(深圳)有限公司 Product catalog intelligent search system and method
CN1691013A (en) * 2004-04-29 2005-11-02 Nec软件有限公司 Structured Natural Language Query and Knowledge Systems
CN1881208A (en) * 2005-06-14 2006-12-20 联想(北京)有限公司 Construction method for dynamic structured query language statement

Also Published As

Publication number Publication date
CN101206654A (en) 2008-06-25

Similar Documents

Publication Publication Date Title
US12222944B2 (en) Processing database queries using format conversion
US11841854B2 (en) Differentiation of search results for accurate query output
US7870485B2 (en) Method and apparatus for generating multiple documents using a template and a data source
JP4378646B2 (en) Information processing apparatus, information processing method, and program
US10459904B2 (en) Real time mapping of user models to an inverted data index for retrieval, filtering and recommendation
KR101231560B1 (en) Method and system for discovery and modification of data clusters and synonyms
US7562088B2 (en) Structure extraction from unstructured documents
US20080027902A1 (en) Method and apparatus for selecting data records from versioned data
US20070233648A1 (en) Execution cost reduction of sampled queries in a database
US8224839B2 (en) Search query extension
JP2013513144A (en) Method, apparatus, and computer program for retrieving annotations of data items in a view
US7194449B2 (en) Method and system for optimizing snow flake queries
CN102955844A (en) Presenting search results based upon subject-versions
KR100452086B1 (en) Search System For Providing Information of Keyword Input Frequency By Category And Method Thereof
US20210081415A1 (en) Query classification alteration based on user input
US11720626B1 (en) Image keywords
CN101206654B (en) Database query system and method with intelligent query capability
JP5310196B2 (en) Classification system revision support program, classification system revision support device, and classification system revision support method
KR102732683B1 (en) Apparatus for searching video
CN106557586B (en) Database access processing method and device
WO2013096882A1 (en) Method and apparatus for optimizing content targeting
CN104834664A (en) Optical disc juke-box oriented full text retrieval system
CN119377453B (en) Query method based on multimodal database
TWI845796B (en) Knowledge graph association search method and system
CN113448966A (en) Order data multidimensional spreadsheet system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CB03 Change of inventor or designer information
CB03 Change of inventor or designer information

Inventor after: Guo Hongjie

Inventor after: Wang Huichao

Inventor after: Cong Rong

Inventor after: Chen Zhaojin

Inventor after: Li Juan

Inventor before: Qiu Quancheng

Inventor before: Ye Jianhua

TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20171017

Address after: The 4 District of Hebei city of Langfang province Guangyang District Pipeline Bureau 28 Building 2 unit 502

Co-patentee after: Wang Huichao

Patentee after: Guo Hongjie

Co-patentee after: Cong Rong

Co-patentee after: Chen Zhaojin

Co-patentee after: Li Juan

Address before: Taipei City, Taiwan, China

Patentee before: Inventec Corporation

CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20100414

Termination date: 20171222