IP Library Granted Patent US 7,366,713
Granted Patent B2
US 7,366,713 · App. 10/418,882 · Granted Apr 29, 2008

Extensible rules engine in a database management system

Assignee: Oracle International Corporation
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 7,366,713
App. No.
10/418,882
Granted
Apr 29, 2008
Kind
B2
Abstract

An extensible rules engine that uses database technology provides a rules evaluation service for applications external to the database server or database management system. Applications are able to utilize the rules engine to provide alternative behaviors based on information against which specified conditions are evaluated. A framework is provided for specifying data definitions that can be referenced by user-defined rules, through creation and use of an evaluation context. Application-specific data types can be defined by specifying data tables and/or variables that can be referenced by rules created for evaluation against data that is associated with the evaluation context. The data against which rules are evaluated can be provided as an in-memory object. A security model is provided in which the privilege to create rules according to a particular evaluation context is controlled by one privilege, whereas the privilege to access underlying tables or variables is controlled by another privilege.

Claims (64)

1. A method for evaluating rules in a database system, the method comprising the steps of:

receiving, at the database system and from a particular application, an evaluation context;

wherein the evaluation context specifies a definition of a data object associated with the particular application;

receiving, at the database system and from the particular application, a set of one or more rules;

wherein each rule in the set of one or more rules includes at least one rule condition;

wherein a particular rule in the set of one of more rules includes a particular rule condition that references said data object;

within the database system, (a) selecting the evaluation context, from a plurality of available evaluation contexts, as the evaluation context to use to evaluate the particular rule, (b) using the evaluation context to determine the definition of the data object, and (c) evaluating the particular rule against the data object based on the definition of the data object, to determine whether the particular rule condition is satisfied; and

sending, from the database system to the particular application, an indication of whether the particular rule condition is satisfied.

2. The method of claim 1 , wherein the step of receiving an evaluation context includes receiving an evaluation context that specifies a list of one or more data tables that are referenced in said particular rule condition.

3. The method of claim 1 , wherein the step of receiving an evaluation context includes receiving an evaluation context that defines one or more variables that are referenced in said particular rule condition.

4. The method of claim 1 , wherein the step of receiving an evaluation context includes receiving an evaluation context that specifies a list of one or more data tables that are referenced in a rule condition of at least one rule from said set, and defines one or more variables that are referenced in a rule condition of at least one rule from said set.

5. The method of claim 1 ,

wherein the step of receiving an evaluation context includes receiving an evaluation context that specifies a list of one or more data tables that are referenced in said particular rule condition; and the method further comprises the steps of:

controlling management of the evaluation context with a first security privilege; and

controlling access to the one or more tables with a second security privilege that is different than the first security privilege.

6. The method of claim 1 ,

wherein the steps of receiving include receiving from a software application;

wherein the step of evaluating is performed by a database server; and

wherein the software application is different than the database server.

7. The method of claim 6 , further comprising the step of:

receiving data from the software application; and

without persistently storing the data in the database system, evaluating the set of rules against the data received from the software application is evaluated.

8. The method of claim 1 ,

wherein the step of receiving a set of rules includes receiving a rule that includes a first rule condition and a second rule condition that is disjunctively related to the first rule condition and wherein the first rule condition includes a third rule condition and a fourth rule condition that is conjunctively related to the third rule condition;

wherein the data that the one or more rules are evaluated against includes third data that is associated with the third condition and does not include fourth data that is associated with the fourth condition; and

wherein the step of evaluating includes

evaluating the third condition against the third data to determine whether the third condition is satisfied by the third data;

if the third condition is not satisfied by the third data, then returning an indication that the first condition is not satisfied; and

if the third condition is satisfied by the third data, then returning an indication that the first condition may be satisfied.

9. The method of claim 8 , wherein the third condition is a simple rule condition.

10. The method of claim 8 , wherein:

if at least one indication is returned that the first condition is satisfied or that the second condition is satisfied, then returning an indication that the rule is satisfied;

if no indication is returned that the first condition is satisfied or that the second condition is satisfied and if at least one indication is returned that the first condition may be satisfied or that the second condition may be satisfied, then returning an indication that the rule may be satisfied; and

if no indication is returned that the first condition is satisfied or that the second condition is satisfied and no indication is returned that the first condition may be satisfied or that the second condition may be satisfied, then returning an indication that the rule is not satisfied.

11. The method of claim 1 , wherein:

the step of receiving an evaluation context includes receiving an evaluation context that is associated with a subset of the set of

the evaluation context is selected, from the plurality of available evaluation contexts, based on the particular rule belonging to said subset.

12. The method of claim 1 , wherein:

the step of receiving an evaluation context includes receiving an evaluation context that is associated with each rule of the set of rules; and

the evaluation context is selected, from the plurality of available evaluation contexts, based on the association between the evaluation context and the set of rules.

13. The method of claim 1 , wherein the step of receiving an evaluation context and the step of receiving the set of rules are performed by a single act of receiving a message that includes both the evaluation context and the set of rules.

14. A computer-readable storage medium carrying one or more sequences of instructions which, when executed by one or more processors, causes the one or more processors to perform the method recited in claim 1 .

15. A computer-readable storage medium carrying one or more sequences of instructions which, when executed by one or more processors, causes the one or more processors to perform the method recited in claim 2 .

16. A computer-readable storage medium carrying one or more sequences of instructions which, when executed by one or more processors, causes the one or more processors to perform the method recited in claim 3 .

17. A computer-readable storage medium carrying one or more sequences of instructions which, when executed by one or more processors, causes the one or more processors to perform the method recited in claim 4 .

18. A computer-readable storage medium carrying one or more sequences of instructions which, when executed by one or more processors, causes the one or more processors to perform the method recited in claim 5 .

19. A computer-readable storage medium carrying one or more sequences of instructions which, when executed by one or more processors, causes the one or more processors to perform the method recited in claim 6 .

20. A computer-readable storage medium carrying one or more sequences of instructions which, when executed by one or more processors, causes the one or more processors to perform the method recited in claim 7 .

21. A computer-readable storage medium carrying one or more sequences of instructions which, when executed by one or more processors, causes the one or more processors to perform the method recited in claim 8 .

22. A computer-readable storage medium carrying one or more sequences of instructions which, when executed by one or more processors, causes the one or more processors to perform the method recited in claim 9 .

23. A computer-readable storage medium carrying one or more sequences of instructions which, when executed by one or more processors, causes the one or more processors to perform the method recited in claim 10 .

24. A computer-readable storage medium carrying one or more sequences of instructions which, when executed by one or more processors, causes the one or more processors to perform the method recited in claim 11 .

25. A computer-readable storage medium carrying one or more sequences of instructions which, when executed by one or more processors, causes the one or more processors to perform the method recited in claim 12 .

26. A computer-readable storage medium carrying one or more sequences of instructions which, when executed by one or more processors, causes the one or more processors to perform the method recited in claim 13 .

27. An apparatus for evaluating rules in a database system, the apparatus comprising:

one or more processors;

memory, operatively coupled to the one or more processors;

means for receiving, at the database system and from a particular application, an evaluation context;

wherein the evaluation context specifies a definition of a data object associated with the particular application;

means for receiving, at the database system and from the particular application, a set of one or more rules;

wherein each rule in the set of one or more rules includes at least one rule condition;

wherein a particular rule in the set of one of more rules includes a particular rule condition that references said data object;

means, within the database system, for (a) selecting the evaluation context, from a plurality of available evaluation contexts, as the evaluation context to use to evaluate the particular rule, (b) using the evaluation context to determine the definition of the data object, and (c) evaluating the particular rule against the data object based on the definition of the data object, to determine whether the particular rule condition is satisfied; and

means for sending, from the database system to the particular application, an indication of whether the particular rule condition is satisfied.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Apr 17, 2003
From: KALUSKAR, SANJAY; WANG, WEI; GAWLICK, DIETER; STAMOS, JAMES
To: ORACLE INTERNATIONAL CORPORATION
Reel/Frame 013995/0752 →
Continuity (3)
Continuation In Part 1025438300 · Sep 24, 2002
Provisional Application 6037801800 · May 10, 2002
Related Publication 20030212657A1 · Nov 13, 2003