Question about partition function

  • In what system table/view can I find all values of a partition function? I need it to programmatically alter partition function on a weekly basis.

    Thanks

  • The data relevant to exploring SQL Server partitioning functions/schemes are spread throughout a number of views. You'll want to look at sys.partition_range_values, sys.partition_functions, sys.partitions, among possibly others. Use BOL to show you all of them.

    By the way, you are planning on using the ALTER PARTITION FUNCTION method for changing the values right?

    John Rowan

    ======================================================
    ======================================================
    Forum Etiquette: How to post data/code on a forum to get the best help[/url] - by Jeff Moden

  • Thanks, John. sys.partition_range_values is what I wanted.

  • Yes, I will use ALTER PARTITION FUNCTION.

  • Good, just checking. You never know, without asking, if someone is wanting to attempt to modify the system tables directly or not.

    John Rowan

    ======================================================
    ======================================================
    Forum Etiquette: How to post data/code on a forum to get the best help[/url] - by Jeff Moden

Viewing 5 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply