Professional Documents
Culture Documents
364-C-2930-Worksheet Date Functions and Group Functions
364-C-2930-Worksheet Date Functions and Group Functions
SCHOOL
write the output of the following along with the data type of
returning value/output:
select curdate();
select sysdate();
select sysdate()+1;
select curdate()+1;
select now();
select date(sysdate());
select day(sysdate());
select dayname(sysdate());
select month(sysdate());
select monthname(sysdate());
select now(),sleep(5),now();
D). Explain why the following queries give different outputs on execution:
Output: 5
Output: 8
Note: There are total 6 rows in the table inventory, but rate column is having 2
NULL values .
a. (20+22+22+22)/4
b.(20+22+22+22)/6