Hi,
Total no of records in a table
select count(*) from tablename
Total number of records in a database
For userdefined table
SELECT
[TableName] = so.name,
[Table id]=so.id,
[RowCount] = MAX(si.rows)
into #Temp1 FROM
sysobjects so, sysindexes si
WHERE
so.xtype = 'U'
AND si.id = OBJECT_ID(so.name)
GROUP BY
so.name,so.id
ORDER BY
3 DESC
select sum([rowcount]) from #temp1
drop table #temp1
HTH
from
Killer