Mohit Agrawal
Success is Journey it's not a destination
Menu
Home
Sql server 2008
Differences
May 12, 2010
Sql Server : list of tables which have no records in a database.
select distinct o.name as TableName, x.rowcnt as Table_RowCount
from sysobjects o
inner join sysindexes x
on o.id = x.id
where x.rowcnt = 0 and x.groupid = 1
and o.type = 'U'
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment