1. Field of the Invention
The invention generally relates to computer database systems. More particularly, the invention relates to techniques for selecting rule engines for processing abstract rule sets.
2. Description of the Related Art
Databases are well known systems for storing, searching, and retrieving information stored in a computer. The most prevalent type of database used today is the relational database, which stores data using a set of tables that may be reorganized and accessed in a number of different ways. Users access information in relational databases using a relational database management system (DBMS).
Each table in a relational database includes a set of one or more columns. Each column typically specifies a name and a data type (e.g., integer, float, string, etc), and may be used to store a common element of data. For example, in a table storing data about patients treated at a hospital, each patient might be referenced using a patient identification number stored in a “patient ID” column. Reading across the rows of such a table would provide data about a particular patient. Tables that share at least one attribute in common are said to be “related.” Further, tables without a common attribute may be related through other tables that do share common attributes. A path between two tables is often referred to as a “join,” and columns from tables related through a join may be combined to from a new table returned as a set of query results.
Queries of a relational database may specify which columns to retrieve data from, how to join the columns together, and conditions (predicates) that must be satisfied for a particular data item to be included in a query result table. Current relational databases require that queries be composed in complex query languages. Today, the most widely used query language is Structured Query Language (SQL). However, other query languages are also used. A SQL query is composed from one or more clauses set off by a keyword. Well-known SQL keywords include the SELECT, WHERE, FROM, HAVING, ORDER BY, and GROUP BY keywords. Composing a proper SQL query requires that a user understand both the structure and content of the relational database as well as the complex syntax of the SQL query language (or other query language). The complexity of constructing an SQL statement, however, generally makes it difficult for average users to compose queries of a relational database.
Because of this complexity, users often turn to database query applications to assist them in composing queries of a database. One technique for managing the complexity of a relational database, and the SQL query language, is to use database abstraction techniques. Commonly assigned U.S. Pat. No. 6,996,558, entitled “Application Portability and Extensibility through Database Schema and Query Abstraction,” discloses techniques for constructing a database abstraction model over an underlying physical database.
U.S. Pat. No. 6,996,558 discloses embodiments of a database abstraction model constructed from logical fields that map to data stored in the underlying physical database. Each logical field defines an access method that specifies a location (i.e., a table and column) in the underlying database from which to retrieve data. Users compose an abstract query by selecting logical fields and specifying conditions. The operators available for composing conditions in an abstract query generally include the same operators available in SQL (e.g., comparison operators such as =, >, <, >=, and, <=, and logical operators such as AND, OR, and NOT). Data is retrieved from the physical database by generating a resolved query (e.g., an SQL statement) from the abstract query. Because the database abstraction model is tied to neither the syntax nor the semantics of the physical database, additional capabilities may be provided by the database abstraction model without having to modify the underlying database. Thus, the database abstraction model provides a platform for additional enhancements that allow users to compose meaningful queries easily, without having to disturb existing database installations.
Data that is collected and stored in a database can be used as input to analysis routines for various purposes, including know-how management, decision making and statistical analysis. For instance, in a broad variety of applications, analysis routines are executed on query results obtained by executing corresponding queries against an underlying database.
Analysis routines can be defined by rule sets including one or more rules, each having predicates and actions. Commonly, the rules will have the structure “IF [predicate] THEN [action].” A rule predicate is a conditional statement evaluated in a rule engine. If the predicate is satisfied (i.e., the condition is met), then the associated rule action is executed. In other words, a set of rules can be used to implement an analysis routine, and a rule engine can evaluate predicates and fire or execute actions defined in the rules. Where actions of rules are defined to provide recommendations for users, such as treatment recommendations for doctors in medical institutions, the rules can be defined such that corresponding predicates reflect expert-based knowledge of possible diagnoses and evaluations of patient conditions. In other words, rules can be implemented to assist doctors by making diagnosis recommendations, drug recommendations, providing reminders of required verifications and checks, etc.
However, the creation of rules is generally a complex and difficult process which requires detailed knowledge of a corresponding database(s). More specifically, for each predicate and each action of the given rule that the user wants to create, the user requires an understanding of the database schema in order to look up a corresponding column name in the underlying database table(s). One technique for managing the creation of rules is to use abstract rule sets. Commonly assigned U.S. application Ser. No. 11/272,583 (hereafter “the '583 application”), entitled “Abstract Rule Sets,” discloses techniques for using abstract rule sets.
The '583 application discloses that abstract rules must be translated into an executable form that can be processed by the rule engine. Each rule engine includes functions for processing the executable rules. For example, a rule having the predicate “If AVG (level)>40 . . . ” requires that the rule engine include the statistical function “AVG,” or average. Thus, if a rule engine does not include a function required to process a given rule, that rule cannot be processed on that rule engine.
In some situations, a variety of rule engines may be available to analyze the rule sets. The rule engines may differ in functionality. For example, a rule engine that is specialized for statistical analysis may not include fuzzy logic functions. On other hand, a rule engine that is specialized for artificial intelligence analysis may include fuzzy logic functions, but may not include statistical analysis functions.
In addition, the rule engines can differ in the cost to perform a particular function. For example, a rule engine that is developed internally by a company may not have any cost associated with its use. However, rule engines may also be purchased from vendors with different licensing and cost arrangements. For example, one rule engine may be purchased with an enterprise license that allows unlimited use of all included functions by all employees of a company for a flat fee. Another rule engine may be purchased with a per user license that allows the use of all included functions for a maximum of five concurrent users at a time. Yet another rule engine may be purchased on a Software As A Service (SAAS) basis, in which functions on a remote hosted system are used as required, and the cost is assessed for each use. Yet another rule engine may be purchased with costs based on Central Processing Unit (CPU) utilization. Yet another rule engine may be purchased with varying costs for the different included functions. Because of these differences between various rule engines, it may be desirable to select different rule engines depending on circumstances around a particular need.
Therefore, there is a need for techniques for selecting rule engines for processing abstract rules based on functionality and cost.