摘要 |
Method and computer system for logically evaluating a Boolean expression used in a query statement to optimize the query. The Boolean expression refers to an attribute and includes a plurality of conditions. The Boolean expression is received ( 410 ) and decomposed ( 420 ) into the plurality of conditions. For each condition at least one condition value referring to the attribute is extracted ( 421 ) from the condition. The at least one condition value is then inserted ( 422 ) into a condition value list in sorted order. A relationship vector of the at least one condition value is initialized ( 423 ). Then the relationship vectors of the at least one condition value and of each further condition value that is in the condition list and that is in the value range of the condition are adjusted ( 424 ). After having processed all conditions the Boolean expression may be reducing ( 430 ) according to each relationship vector.
|