Follow Our FB Page << CircleMedia.in >> for Daily Laughter. We Post Funny, Viral, Comedy Videos, Memes, Vines...


what is execute scalar?

Answers were Sorted based on User's Feedback



what is execute scalar?..

Answer / thirushakar

Scalar will return only one value.
(ie we can read or write only one data at the time)

Is This Answer Correct ?    33 Yes 11 No

what is execute scalar?..

Answer / versha

When we want any aggreagate answer then we use execute
scaler examples like avg,sum etc
this return one row and one column

Is This Answer Correct ?    24 Yes 2 No

what is execute scalar?..

Answer / anjeswar

It Returns Single Scalar value as a result

Is This Answer Correct ?    18 Yes 5 No

what is execute scalar?..

Answer / muthu kumar

when we want to retrieve data that has single value then we
can prefer to execute scalar.

Is This Answer Correct ?    13 Yes 4 No

what is execute scalar?..

Answer / prabhat saxena

execute scalar return a object type value, by defalut it
will return first row of fst column value, mostly we used
it with aggregate function like sum(),max(),min(),avg()....

Is This Answer Correct ?    13 Yes 4 No

what is execute scalar?..

Answer / tonny

Executes the query, and returns the first column of the
first row in the result set returned by the query.
Additional columns or rows are ignored.

Is This Answer Correct ?    7 Yes 2 No

what is execute scalar?..

Answer / yograj pandey

Use the ExecuteScalar method to retrieve a single value (for example, an aggregate value) from a database. This requires less code than using the ExecuteReader method, and then performing the operations that you need to generate the single value using the data returned by a SqlDataReader.

A typical ExecuteScalar query can be formatted as in the following C# example:

cmd.CommandText = "SELECT COUNT(*) FROM dbo.region";
Int32 count = (Int32) cmd.ExecuteScalar();

Is This Answer Correct ?    6 Yes 1 No

what is execute scalar?..

Answer / usha

This method is used to execute commands that return single
value rather than resultset.

Is This Answer Correct ?    10 Yes 6 No

what is execute scalar?..

Answer / adsd

scalar will returns single value.scalar eg like avg,sum etc
it vl return oly one column as output

Is This Answer Correct ?    4 Yes 0 No

what is execute scalar?..

Answer / vivek kumar

execute scalar method return only one value that means you
can use this with max, min, sum function

Is This Answer Correct ?    3 Yes 1 No

Post New Answer



More ADO.NET Interview Questions

What is ado object model?

0 Answers  


What are the Different layers in ADO.Net?

10 Answers   eXensys,


What is difference between executenonquery and executequery?

0 Answers  


How can we check that some changes have been made to dataset since it was loaded?

0 Answers  


What is azure ado?

0 Answers  






what is connection pooling ?

3 Answers   Vertex,


can u tell me the how to get the print for the form

2 Answers   Crea,


Explain the difference between data reader and data adapter?

0 Answers  


What is data access pattern?

0 Answers  


What is the full form of ado.net?

0 Answers  


Differnce between Stored procedure and user defined functions?

17 Answers   Microsoft, Symphony,


Differences between dataset.clone and dataset.copy?

2 Answers   Ksb, TCS,






Categories