i have table T!.

A B C D
NULL 1 2 3
4 NULL 5 6
7 8 NULL 9
10 11 12 NULL.


I WANT COUNT OF NULL VALUES IN TABLE. WRITE A QUERY.

Answer Posted / abinash_mishra

SELECT a_null + b_null + c_null + d_null
FROM (SELECT COUNT (DECODE (a, NULL, 1, NULL)) a_null,
COUNT (DECODE (b, NULL, 1, NULL)) b_null,
COUNT (DECODE (c, NULL, 1, NULL)) c_null,
COUNT (DECODE (d, NULL, 1, NULL)) d_null
FROM t_null);

Is This Answer Correct ?    6 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is json a nosql?

541


How to use sql*plus built-in timers?

578


What is localdb mssqllocaldb?

623


Is primary key always clustered index?

538


What is difference between sql and mysql?

537






What is a recursive stored procedure?

621


What is package in pl sql?

579


Explain the rollback statement?

577


Can we create table in function?

572


How to take user input in pl sql?

705


How to place comments in pl/sql?

605


What is right join sql?

536


How can you load multi line records? : aql loader

658


What schema means?

527


Which is better varchar or nvarchar?

550