use pubs
select name from sysobjects where type='U'
得到数据
titleauthor
stores
sales
roysched
discounts
jobs
pub_info
employee
authors
publishers
titles
我想得到它们的实际数据条数
如
titleauthor 35
stores 40
sales 88
roysched
discounts
jobs
pub_info
employee
authors
publishers
titles
------解决方案--------------------
- SQL code
SELECT a.name AS 表名, b.rows AS AS 记录数from sysobjects AS a INNER JOIN sysindexes AS b ON a.ID=b.id AND b.indid<2where a.type='U''