Answered Expirable row entries in Azure Table Storage

  • sexta-feira, 13 de julho de 2012 08:01
     
     

    We write loads of data in Azure Storage. We now need to delete all old data.

    1. Is there a way to delete all table data on or before a given Date?

    2. Are there any APIs for Azure Storage which can write expirable entries into Azure Table Storage i.e. the rows will get auto-deleted post 'x' number of days.

    We ideally would not like to recreate these tables or move to new Azure account. Thanks

Todas as Respostas

  • sexta-feira, 13 de julho de 2012 08:17
     
     

    Unfortunately, there's no API available which would auto-delete old data. This is something you would need to do. Since you want to delete old data and I am assuming you would want to start from the oldest records, what you could do is query by "Timestamp" attribute, fetch the matching entities and then delete those entities.

    Hope this helps.

    Thanks

    Gaurav

  • sexta-feira, 13 de julho de 2012 08:20
     
     

    That is not feasible for us, as we have TBs of data to be deleted.

    How about the 2nd question? Is there any API through which we can write into Table Storage which will get auto-deleted after configured number of days?

  • sexta-feira, 13 de julho de 2012 08:22
     
     Respondido

    How about the 2nd question? Is there any API through which we can write into Table Storage which will get auto-deleted after configured number of days?


    Sorry! No API. You would need to write a service by yourself which would delete the data periodically. The process would still remain the same in this service: Fetch old data and then delete that data.