A method of automatically modifying a computer data query is disclosed herein. The modification of the computer data query can be performed to restrict access to data. The computer data query can be modified by receiving the computer data query, identifying tables in the query and retrieving providers associated with the tables identified in the query. These providers can be linked to one or several predicates. These predicates can be retrieved and used to modify the query. The modified query can then be used to retrieve data from one or several tables identified within the query.