TOOLS
POSTS
-
Author Archives: admin
Oracle ROUND (date)
Function Description Function ROUND (date) returns the date rounded to the unit specified by the date format model. If date format model is omited then date will be rounded to the nearest day. Examples SELECT ROUND(TO_DATE(‘30.11.2011′),’MONTH’) AS “ROUND DATE” FROM … Continue reading
Posted in Oracle SQL Functions
Leave a comment
Oracle NEXT_DAY
Function Description Function NEXT_DAY returns the date of the first weekday named by char that is later than the date. Examples SELECT NEXT_DAY(‘02.11.2011′,’FRIDAY’) AS “NEXT DAY” FROM dual; Result: 4.11.2011 SELECT NEXT_DAY(‘30.11.2011′,’FRIDAY’) AS “NEXT DAY” FROM dual; Result: 2.12.2011
Posted in Oracle SQL Functions
Leave a comment
Oracle MONTHS_BETWEEN
Function DescriptionWatch Full Movie Streaming Online and Download Function MONTHS_BETWEEN returns the number of months between two dates. Examples Oracle PL/SQL SELECT MONTHS_BETWEEN(TO_DATE(‘02.02.2010′,’DD.MM.YYYY’), TO_DATE(‘01.10.2010′,’DD.MM.YYYY’)) FROM dual; Result: -7,96774193548387 SELECT MONTHS_BETWEEN(TO_DATE(‘01.10.2010′,’DD.MM.YYYY’), TO_DATE(‘02.02.2010′,’DD.MM.YYYY’)) FROM dual; Result: 7,96774193548387 SELECT MONTHS_BETWEEN(TO_DATE(‘02.02.2010′,’DD.MM.YYYY’), TO_DATE(‘02.02.2010′,’DD.MM.YYYY’)) FROM dual; … Continue reading
Posted in Oracle SQL Functions
Leave a comment
Oracle LAST_DAY
Function Description Function LAST_DAY returns the last date of the month in DATE datatype. Examples SELECT SYSDATE, LAST_DAY(SYSDATE) “LAST DAY OF MONTH” FROM dual; Result: SYSDATE LAST DAY OF MONTH 15.11.2011 30.11.2011
Posted in Oracle SQL Functions
Leave a comment
Oracle TO_DATE
Function Description Function TO_DATE returns the value of DATE datatype from a VARCHAR2, NVARCHAR2, CHAR, NCHAR datatype. Here you will find Oracle date format elements. Examples SELECT TO_DATE(‘23.07.2011’, ‘DD.MM.YYYY’) FROM dual Result: 23.07.2011 SELECT TO_DATE(‘23.07.2011 15:43:46’, ‘DD.MM.YYYY HH24:MI:SS’) FROM dual Result: … Continue reading
Posted in Oracle SQL Functions
Leave a comment
Oracle DBTIMEZONE
Function Description Function DBTIMEZONE returns the value of database time zone. Examples SELECT DBTIMEZONE FROM dual Result: -05:00
Posted in Oracle SQL Functions
Leave a comment
Oracle CURRENT_TIMESTAMP
Function Description Function CURRENT_TIMESTAMP returns current date and time in the session time zone. Examples SELECT CURRENT_TIMESTAMP FROM dual Result: 29.8.2011 10:36:32,789650 +02:00 SELECT CURRENT_TIMESTAMP(1) FROM dual Result: 29.8.2011 10:40:30,8 +02:00
Posted in Oracle SQL Functions
Leave a comment
Oracle ADD_MONTHS
Function Description Function ADD_MONTHS returns the date PLUS or MINUS integer months. Examples SELECT ADD_MONTHS(SYSDATE, 1) FROM dual Result: 29.9.2011 10:24:48 SELECT ADD_MONTHS(SYSDATE, -1) FROM dual Result: 29.7.2011 10:26:35
Posted in Oracle SQL Functions
Leave a comment
Function Description Function CURRENT_DATE returns date in the session timezone. Examples SELECT CURRENT_DATE FROM dual Result: 29.8.2011 10:33:20