This shows you the differences between two versions of the page.
Next revision | Previous revision Last revision Both sides next revision | ||
interval [2015/09/23 20:27] 127.0.0.1 external edit |
interval [2016/01/27 10:17] dmtolpeko |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== Interval Expressions - PL/HQL Reference ====== | + | ====== Interval Expressions ====== |
Interval expressions allow you to add or subtract interval values to DATE and TIMESTAMP values. | Interval expressions allow you to add or subtract interval values to DATE and TIMESTAMP values. | ||
Line 6: | Line 6: | ||
<code language=sql> | <code language=sql> | ||
- | expression DAYS | DAY | MICROSECONDS | MICROSECOND | + | [INTERVAL] expression DAYS | DAY | MICROSECONDS | MICROSECOND |
</code> | </code> | ||
Line 62: | Line 62: | ||
</code> | </code> | ||
- | **Version**: PL/HQL 0.03 | + | **Example 5**: |
+ | |||
+ | Using INTERVAL keyword: | ||
+ | |||
+ | <code language=sql> | ||
+ | date '2016-01-27' - interval '3' day; | ||
+ | -- | ||
+ | 2016-01-24 | ||
+ | </code> | ||
+ | |||
+ | **Version**: | ||
+ | * INTERVAL keyword - HPL/SQL 0.3.17 | ||
+ | * Introduced - HPL/HQL 0.3 | ||
See also: | See also: |