What is the datatype returned by count(*)

Answers were Sorted based on User's Feedback



What is the datatype returned by count(*)..

Answer / krishna

int data type

Is This Answer Correct ?    4 Yes 1 No

What is the datatype returned by count(*)..

Answer / harsh

SELECT COUNT(*) as "Number of employees"
FROM employees
WHERE salary > 55000;

It would return the following result set:
Number of employees
5
HENCE IT RETURNS 'INT' TYPE.

Is This Answer Correct ?    3 Yes 0 No

What is the datatype returned by count(*)..

Answer / sanjeev kumar

It will return Int or Bigint depend on the size of the row.
(But both are same)

Is This Answer Correct ?    2 Yes 0 No

What is the datatype returned by count(*)..

Answer / sujatha_k

number data type is return.

Is This Answer Correct ?    1 Yes 0 No

What is the datatype returned by count(*)..

Answer / thirumal

count(*) returns the total number of not null values in
given column

Is This Answer Correct ?    3 Yes 3 No

What is the datatype returned by count(*)..

Answer / amar_chhatwani

ir returned Int datadtpe

Is This Answer Correct ?    2 Yes 2 No

What is the datatype returned by count(*)..

Answer / lakshmi narayanan r

It will return INT. Proof is here...
SELECT COUNT(*) AS Total INTO tmpArchiveStoreMaster1 FROM
ArchiveStoreMaster asm
GO
sp_help tmpArchiveStoreMaster1

Name

Owner

Type
Created_datetime
--------------------------------------------------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------------------------------------
------------------------------- -----------------------
tmpArchiveStoreMaster1

dbo

user table 2010-07-06
15:43:05.310



Column_name

Type

Computed Length
Prec Scale Nullable
TrimTrailingBlanks FixedLenNullInSource
Collation
--------------------------------------------------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------------------------------------
----------------------------------- ----------- ----- -----
-----------------------------------
-----------------------------------
-----------------------------------
--------------------------------------------------------------------------------------------------------------------------------
Total

int

no 4
10 0 yes (n/a)
(n/a)
NULL

Is This Answer Correct ?    0 Yes 0 No

What is the datatype returned by count(*)..

Answer / vikneswaran

number

Is This Answer Correct ?    0 Yes 1 No

What is the datatype returned by count(*)..

Answer / haribabu

it returns how meny columns in the data table (or)
how meny records in the table

Is This Answer Correct ?    1 Yes 4 No

What is the datatype returned by count(*)..

Answer / server.getlasterror().message

Server.GetLastError().Message

Is This Answer Correct ?    2 Yes 5 No

Post New Answer

More SQL Server Interview Questions

What is a scheduled job or what is a scheduled task?

0 Answers  


last function used in MS Access to convert sql what function will use in sql

0 Answers   Cap Gemini,


Difference between Function and Stored Procedure?

9 Answers   C1 India, NA,


After removing a table from database, what other related objects have to be dropped explicitly?

0 Answers  


What is compression - row-level and page-level compression?

0 Answers  






Why are you getting errors when creating a new odbc dsn?

0 Answers  


Please explain that what are the basic functions for master, msdb, model, tempdb and resource databases? : SQL Server Architecture

0 Answers  


Which is the main third-party tool used in sql server?

0 Answers  


Can you explain the role of each service?

1 Answers  


What is the difference between having clause and where clause in sql server?

0 Answers  


What is the difference between dataadapter and datareader?

0 Answers  


What is conditional split?

0 Answers  


Categories