1. A method comprising the steps of: receiving a computer programming language database query; generating at least one relational algebraic expression in response to said query by means of a equivalence rule involving the multiset version of the theta-semijoin operator, said rule being ##EQU63## where .theta..sub.2 involves only the attributes in attrs(Q) .orgate.attrs(E.sub.1), ##EQU64## Q denotes a query, E (with or without subscripts) denotes relational expressions, attrs(X) denotes attributes of the result of X, .sub..theta. denotes the multiset .theta.-join, and .sub..theta. denotes the multiset .theta.-semijoin, and .theta. (with or without subscript) denotes quantifier-free predicates; selecting at least one of said relational algebraic expressions; and accessing said computer programming language database based on said selected expression.