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

Which column of the user triggers data dictionary view displays the database event that will fire the trigger?

970


What is blind sql injection?

990


what is the use of anchoring object? what r the difference between anchoring object & enclosing object? can any one tell me all the details?

2412


What does bitemporal mean?

1009


List different type of expressions with the example.

893


Why is a primary key important?

967


Are stored procedures faster than dynamic sql?

980


What is a Mapplet?

1057


Can we call stored procedure in function?

903


What is nosql db?

923


What is sql procedures and functions?

954


What is the difference between sql and mysql?

1051


What is sql data?

923


What is the location of pre_defined_functions.

1111


I need a function for a train ticket reservation please answer it thanks in advance

957