Jump to:

23481 Posts in 18951 Topics by 2878 members

General Questions

SilverStripe Forums » General Questions » Clear Versioning History (just once)

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 1475 Views
  • DeklinKelly
    Community Member
    197 Posts

    Clear Versioning History (just once) Link to this post

    I created a site for my client, and to test it I created many rubbish pages. I also added rubbish content to real pages before adding new pages. I deleted the rubbish pages and content however the data is still available in the administrative area through versioning history.

    How can I clear all versioning history so only versions from now on will be preserved?

  • ChrisBryer
    Community Member
    95 Posts

    Re: Clear Versioning History (just once) Link to this post

    the only way i know of to dump the versioning history is to empty the database table SiteTree_versions. if you have extended sitetree and added database fields, there will be extra tables like products, products_Live, and products_versions that will contain the extended data, and you could probably dump the data in those extended _versions tables as well.

    NOTE::: this will permanently delete all versions and you wont be able to get it back!

    I'd test locally before messing with a live site too, so you know what to expect.

    oh, and back up the database before you try it too, so you can recover the data if you need.

    good luck,

  • BuddhaSource
    Community Member
    57 Posts

    Re: Clear Versioning History (just once) Link to this post


    Was searching arround for the solution, although I knew that I can truncate data from Database directly but was hoping if this was already included in SilverStripe admin panel.

    You can truncate all the modules table postfix with "_version"

Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.