Add queries for transitive query attribute