build queries before of rules in PackageBuilder