if it's any help...create table OrgSearchResult(id int identity(1,1) PRIMARY KEY,org_id uniqueidentifier,Name nvarchar(128), plan_year int, device_id uniqueidentifier)select count(id) as TotalRowNum from OrgSearchResultwhere id > 0 |--Compute Scalar(DEFINE:([Expr1002]=Convert([Expr1003]))) |--Stream Aggregate(DEFINE:([Expr1003]=Count(*))) |--Clustered Index Seek(OBJECT:([CRM2].[dbo].[OrgSearchResult].[PK__OrgSearchResult__6BAFC5BE]), SEEK:([OrgSearchResult].[id] > 0) ORDERED FORWARD)select count(id) as TotalRowNum from OrgSearchResult |--Compute Scalar(DEFINE:([Expr1002]=Convert([Expr1003]))) |--Stream Aggregate(DEFINE:([Expr1003]=Count(*))) |--Clustered Index Scan(OBJECT:([CRM2].[dbo].[OrgSearchResult].[PK__OrgSearchResult__6BAFC5BE]))
Go with the flow & have fun! Else fight the flow