Sybernet / Supplied Functions Reference
Release 3.00
Oct 14, 2002
backwards forwards

HTTP.DATEADD

The dateadd function adds an interval to a date you specify.

Syntax

FUNCTION DATEADD
(
    DATEPART                      VARCHAR2
,   NUMBER                        NUMBER
,   DATETIME1                     DATE
)
RETURN DATE;

Parameters

Parameter Description
datepart
 
Date Part     Abbreviation   Values
------------- -------------- ---------------------------------
year          yy             1753 - 9999
quarter       qq             1 - 4
month         mm             1 - 12
dayofyear     dy             1 - 366
day           dd             1 - 31
week          wk             1 - 54
weekday       dw             1 - 7 (1 is Sunday in us_english)
hour          hh             0 - 23
minute        mi             0 - 59
second        ss             0 - 59
number
 
The interval to add or subtract from date.
datetime1
 
A date value.

Returns

A date produced by adding date parts to another date.

Example

The following example illustrates how to call dateadd.

select http.dateadd('day',sysdate-10,sysdate) from dual;

--------------
            10



Sybernet is a trademark of SRI International.
Copyright © 1996-2009 SRI International. All Rights Reserved.
Denis D. Workman / http://Sybernet.sri.com/