none
Query Store Not Releasing Space and Creates QDS_Loaddb waits and an inoperable database

    Question

  • Hi,

    I'm having problems with the query store on one of my production databases. It was set to a maximum size of 500MB with size based cleanup. Yet, it grew to over 20 GB with no free space left in the query store. When it reached this point, the underlying database became unusable as queries got stuck with a wait type QDS_Loaddb. 

    Furthermore, I am unable to clear space from this query store using 

    ALTER DATABASE [QueryStoreDB] SET QUERY_STORE CLEAR;

    It is still at 20GB with no free space.

    Are there any other methods to cleaning up a full query store? I'm running 2016 Enterprise version 13.0.1601.5

    Wednesday, May 3, 2017 6:13 PM

All replies

  • That is the RTM version of SQL 2016, and you should absolutely install Service Pack 1, and I would suggest that you apply the most recent Cumulative Update as well.

    If this solves your problems, I don't know. Well, maybe it will, this it would require a restart of SQL Server, which I suspect might clear things up anyway.

    Wednesday, May 3, 2017 9:32 PM