what is count(1) [message #1710] |
Thu, 23 May 2002 14:10 |
pavani
Messages: 32 Registered: April 2002
|
Member |
|
|
i saw using count(1) in select statements does that mean 1st column of the table i'm doubt of that plz let me know
|
|
|
Re: what is count(1) [message #1713 is a reply to message #1710] |
Thu, 23 May 2002 21:17 |
Amit
Messages: 166 Registered: February 1999
|
Senior Member |
|
|
N0 it is not like that
count(1) means column 1 count
I think
query select count(1) from table name requires less time
than
select count(*) from table name but both queries will give same output
|
|
|
Re: what is count(1) [message #1719 is a reply to message #1710] |
Fri, 24 May 2002 01:43 |
M.P.KIRAN KUMAR
Messages: 9 Registered: May 2002
|
Junior Member |
|
|
hi,
count(*) displays number of rows , in that * means
all the columns, so if we use count(1) it will take only one column i.e. p.k. so the fetching will be very fast....
another way u can use count(rowid)..
bye
|
|
|