I see the following query in an Azure SQL Database (that has Forced Parameterization = FORCED, Parameter Sniffing = ON, and Query Optimizer Fixes = ON) from within Query Store:
delete from [CMS_WebFarmTask] where [TaskIsAnonymous] = @0 and [TaskID] not in ( select [TaskID] from [CMS_WebFarmServerTask] ) and [TaskCreated] < dateadd ( minute , @1 , getdate ( ) )
It has a large number of plans (17 in the last hour), despite both parameters being integers with identical values in each plan:
<ParameterList> <ColumnReference Column="@1" ParameterDataType="int" ParameterCompiledValue="(-3)" /> <ColumnReference Column="@0" ParameterDataType="int" ParameterCompiledValue="(0)" /> </ParameterList>
Why isn't only one plan being used?