Cc-5 SQL Table
Cc-5 SQL Table
HOSPITAL.
TABLE: HOSPITAL
Output:-
(i) Select COUNT(distinct TYPE) from INTERIORS;
Ans.: COUNT(DISTICNT TYPE)
5
(ii) Select AVG(DISCOUNT) from INTERIORS where
TYPE = " Baby Cot";
Ans.: AVG (DISCOUNT)
13
(iii) Select SUM(Price) from INTERIORS where
DATOFSTOCK < ( 12/02/02);
Ans.: SUM(PRICE)
53000
Write the output on the basis of given
table
Output:-
(i) Select COUNT(distinct TYPE) from INTERIORS;
Ans.: COUNT(DISTICNTTYPE)
5
(ii) Select AVG(DISCOUNT) from INTERIORS where
TYPE = " Baby Cot";
Ans.: AVG(DISCOUNT)
13
(iii) Select SUM(Price) from INTERIORS where
DATOFSTOCK < ( 12/02/02};
Ans.: SUM(PRICE) 53000