Identifying which tables are partitioned in a database

  • does anybody have a sql script for identifying which tables are partitioned in a database?

  • this will show you everything, which includes all the objects in the default partition, and the commented out WHERE statement will show you the objects that exist in other partitions, which is what you'd like, right?

    select object_name(object_id) As ObjName,*

    from sys.partitions

    --WHERE partition_number <> 1

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • Thanks you for the query. Actually since I posted this I realized that these partition schemes and partition functions where created by Database Tuning Advisor, so, and there are not any partitioned tables or indexes in my database, however, when I try to delete the partition schemes it say's that there are tables that are using the scheme.

Viewing 3 posts - 1 through 2 (of 2 total)

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