SQLTeam.com | Weblogs | Forums

Cost increases when the same plan is forced on a query


#1

I am trying to perform the foreign plan costing. For that I need to force the plan over the whole selectivity space. But as I am using the "Use plan" option over a query with the same plan that was returned by sql server, the total subtree cost of the plan increases by 60-70%. I am not able to figure out why is it so?

I am using SQL Server 2016 Developer version. I have 100gb of TPC-DS data loaded in the server.