using subquery how can i calculate working days in a month?
Answer Posted / mayru
SELECT COUNT( *)
FROM
(SELECT ROWNUM RNUM
FROM ALL_OBJECTS
WHERE ROWNUM <= TO_DATE('01-OCT-2011') - TO_DATE('01-SEP-2011') + 1
)
WHERE TO_CHAR(TO_DATE('01-SEP-2011') + RNUM - 1, 'DY') NOT IN('SAT', 'SUN');
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is sql procedures and functions?
What is a scalar value in sql?
What is the purpose of the sql select top clause?
what is timestamp in mysql? : Sql dba
Explain what is sql?
What is pl sql script?
what is 'mysqladmin' in mysql? : Sql dba
Does truncate free space?
what is innodb? : Sql dba
What is difference between stored procedure and trigger?
mention if it is possible to import data directly from t-sql commands without using sql server integration services? If yes, what are the commands? : Transact sql
What are the types of records?
What is group function in sql?
Why should I use postgresql?
Is a table valued function object?