G
Guest
I have a table which has a million records. Each night it get trashed and
re-built.
I want to run a select statment and pass the results into a variable to let
me know if it contains more than 0 records.
I don't want to do this because it takes to long to perform the count.
declare @counttable int
select @counttable = count(*) from [tablename]
Is there a quicker way to do what I want to achieve
re-built.
I want to run a select statment and pass the results into a variable to let
me know if it contains more than 0 records.
I don't want to do this because it takes to long to perform the count.
declare @counttable int
select @counttable = count(*) from [tablename]
Is there a quicker way to do what I want to achieve