Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Compare all table records in 2 Databases
Message
 
 
To
06/05/2010 07:44:49
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
General information
Forum:
Microsoft SQL Server
Category:
Database management
Environment versions
SQL Server:
SQL Server 2008
Miscellaneous
Thread ID:
01428886
Message ID:
01463378
Views:
32
>>>Don't you think that it is an overkill for a simple job. I would simply use a T-SQL like this:
>>>
>>>
select object_name(si.id),si.rowcnt from [sys].[sysindexes] si
>>>	inner join [sys].[tables] st
>>>		ON si.id = st.[object_id]
>>>	where si.indid<2 and st.is_ms_shipped = 0
>>>      order by object_name(si.id)
>>>
>>>Cetin
>>
>>Is it only for tables having indexes?
>
>No, why do you think it is?
>PS: However it is better to use Rows instead of RowCnt (table might be partitioned).
>
>Cetin

Thanks. For some reason I thought since it's an inner join to sysindexes it means table should have indexes (as the name suggests). Thanks again.
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform