How to display all Friday's in a year with date?
Answer Posted / dinesh
DECLARE
c date:='01-JAN-15';
d date:='31-DEC-15';
a number(10);
BEGIN
a:=d-c;
FOR i in 1..a
LOOP
IF to_char(c,'DY')='FRI' THEN
DBMS_OUTPUT.PUT_LINE('THIS IS FRIDAY DATE:='|| ' '|| c);
END IF;
c:=c+1;
END loop;
END;
| Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
What is rownum in sql?
what is bcp? When is it used?
explain mysql aggregate functions. : Sql dba
What are the different type of joins in sql?
How do I restart sql?
What are all ddl commands?
What is full join in sql?
What is normalization in sql?
what are the 'mysql' command line arguments? : Sql dba
I need a function for a train ticket reservation please answer it thanks in advance
Can we create view in stored procedure?
what is the difference between join and union? : Sql dba
What is the use of stored procedures?
How to write a query to show the details of a student from students table whose
what is a view? : Sql dba