what will be the output of the below given query, if no
matching records are found : (a.) 0 (b.) null (c.) error
select Avg(salary)
from TableA
where Deptno = 'insurance'
Answer Posted / lalit
Hi,
My understanding is different so it can be a or b. Assume
that there are 10 records and this column can have null
values. If 9 records have null and one record has vale as
zero then the answer would be zero and if all of them have
null then the answer would be null. If no rows satifies the
criteria then it would be null.
| Is This Answer Correct ? | 5 Yes | 7 No |
Post New Answer View All Answers
What is the role of schema in the db2 database?
Define sqlca.
How do I delete a column in db2?
How to compare data between two tables in db2?
What is node in db2?
Explain the function done by data manager?
What db2 400?
Explain about rct in db2?
can all users have the privilage to use the sql statement select * (dml)?
Which isolation level provides maximum concurrency?
What are the bind parameters ibm db2?
List out the buffer pools in db2
How will you return the number of records in table?
What is the latest version of ibm db2?
What is dclgen (declaration generator)?