deleting old partitions

  • i have a table partition on the primary key. It creates daily partitions. How do i delete partitions older than 7 days.

    Do i need to use switch? or can i explicitly drop partitions?

    www.sql-library.com[/url]

  • As far as I know explicitily dropping a partition remains to be an Oracle feature; in the SQL Server world you have to switch the partition out.

    _____________________________________
    Pablo (Paul) Berzukov

    Author of Understanding Database Administration available at Amazon and other bookstores.

    Disclaimer: Advice is provided to the best of my knowledge but no implicit or explicit warranties are provided. Since the advisor explicitly encourages testing any and all suggestions on a test non-production environment advisor should not held liable or responsible for any actions taken based on the given advice.
  • Check out topic "Readme_SlidingWindow" in BOL !

    With partitioning, preparation is crucial !!

    Johan

    Learn to play, play to learn !

    Dont drive faster than your guardian angel can fly ...
    but keeping both feet on the ground wont get you anywhere :w00t:

    - How to post Performance Problems
    - How to post data/code to get the best help[/url]

    - How to prevent a sore throat after hours of presenting ppt

    press F1 for solution, press shift+F1 for urgent solution 😀

    Need a bit of Powershell? How about this

    Who am I ? Sometimes this is me but most of the time this is me

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

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