1. A method for optimizing the execution of a database query involving a target partitioned-database-object, the method comprising: receiving the database query; and if a predicate in the database query uses a partition-mapping function that uses the partitioning schema of a partitioned database-object and a list of columns from one or more tables to express a mapping of the list of column values to the partitions of the partitioned database-object, the method further comprises: determining the compatibility of the partitioning schemas of the target partitioned-database-object and the partitioned database-object; if the partitioning schemas are compatible, and if the list of columns is compatible with the partitioning keys of the target partitioned-database-object and the partitioned database-object, attempting to identify a subset of partitions in the target partitioned-database-object, wherein each partition in the subset satisfies the predicate; and if a subset of partitions is successfully identified, performing the query only on the identified subset of partitions, and not on the other partitions, thereby optimizing the execution of the query by reducing the number of partitions that need to be accessed.