Tuesday, July 13, 2010

How to know the number of rows in all the tables in a SQL server 2005 database?

The blow query will show the number of rows in all the tables in a SQL server 2005 database


select distinct sysobjects.name,sysindexes.rows from sysobjects
inner join sysindexes on sysindexes.id=sysobjects.id
where sysobjects.xtype='u'
order by sysindexes.rows desc

or you can use the below querry to the same details

SELECT OBJECT_NAME(OBJECT_ID) TableName, st.row_count

FROM sys.dm_db_partition_stats st
WHERE index_id < 2
ORDER BY st.row_count DESC

Saturday, July 10, 2010

How to clear the text values of an Ajax ComboBox control?

Today I had Googled a lot to find a solution for clearing the text box values of an Ajax ComboBox, but unfortunately I could find any accurate solution. Then I finally decided to make some changes to the code which is published in my blog (http://rajeshkamalakshan.blogspot.com/2010/05/how-to-get-selected-text-of-microsoft.html) to achieve the above result.

For all you please find the code to clear the text box values of an Ajax ComboBox