Displays the object ID for a specified partition ID and database ID.
partition_object_id(partition_id [, database_id ] )
is the ID of the partition whose object ID is to be retrieved.
is the database ID of the partition.
Displays the object ID for the partition whose partition ID is 2:
select partition_object_id(2)
Displays the object ID for the partition whose partition ID is 14 and whose database ID is 7:
select partition_object_id(14,7)
Returns a NULL value for the database ID because a NULL value is passed to the function:
select partition_object_id( 1424005073, NULL)
----------- NULL (1 row affected)
partition_object_id uses the current database ID if you do not include a database ID.
partition_object_id returns NULL if you use a NULL value for the partition_id.
partition_object_id returns a NULL value if you include a NULL value for database ID.
partition_object_id returns NULL if you provide an invalid or non-existent partition_id or database_id.