How do you find the number of rows in a table?

Answer Posted / anand

select count(*) from table_name will hold good if there isn't any WHERE clause in it as it is a AGGREGATE Function.. (just additional information)

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to create a view and a stored procedure in ms sql server using "create view/procedure" statements?

712


Which Model uses the SET concept

743


Explain the difference between clustered and non-clustered index?

683


What are the new features introduced in SQL Server 2000 (or the latest release of SQL Server at the time of your interview)? What changed between the previous version of SQL Server and the current version?

802


How to select true false based on column value in sql server?

707






Introduction of rollup clause using sum and group by clause?

702


How to provide login information for a new odbc dsn?

692


What is the name of the Database which IBM mainframe uses?

732


What does it mean if @@cursor_row returns a negative number?

717


What do you mean by subquery?

746


Why people hate cursor?

897


Is a primary key unique?

702


What are “lost updates”?

775


How to compare the top two records using sql?

954


How important do you consider cursors or while loops for a transactional database?

703