Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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 / chiranjib

SELECT SUM( CASE WHEN A IS NULL THEN 1
ELSE
CASE WHEN B IS NULL THEN 1
ELSE
CASE WHEN C IS NULL THEN 1
ELSE
CASE WHEN D IS NULL THEN 1
ELSE
0
END
END
END
END ) Tot_Null
FROM T
/

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is full form of rtm?

1008


what tools available for managing mysql server? : Sql dba

1087


How to run sql statements with oracle sql developer?

1073


Why do we use view in sql?

970


how to rename an existing column in a table? : Sql dba

1020


What are pl/sql cursor exceptions?

1110


What is pl/sql language case sensitive?

1131


What is a sql driver?

1004


How do you concatenate in sql?

1029


What is trigger in sql and its types?

1064


What is server name sql?

1153


How do I run a query in pl sql developer?

998


How to change the order of columns in Oracle SQL Plus ?

1058


How do I order by ascending in sql?

1025


What is the use of count (*) in sql?

1056