Enable Query Store in SQL Server

ALTER DATABASE [SMARTPAY] SET QUERY_STORE = on
ALTER DATABASE [SMARTPAY] SET QUERY_STORE (OPERATION_MODE = READ_WRITE, CLEANUP_POLICY = (STALE_QUERY_THRESHOLD_DAYS = 30), MAX_STORAGE_SIZE_MB = 1024)