Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » ElevateDB Technical Support » Product Manuals » ElevateDB Version 2 SQL Manual » Operators » Arithmetic Operators |
Operator | Description |
* | Multiplies the left numeric or interval expression by the right numeric or interval expression. |
/ | Divides the left numeric or interval expression by the right numeric expression. |
- | Subtracts the right numeric, date, time, timestamp, or interval expression from the left numeric, date, time, timestamp, or interval expression. |
+ | Adds the right numeric, date, time, timestamp, or interval expression to the left numeric, date, time, timestamp, or interval expression. |
MOD | Returns the remainder derived from dividing the left numeric or interval expression by the right numeric or interval expression. |
Expression | Interval Type |
DATE - DATE | INTERVAL DAY |
TIME - TIME | INTERVAL HOUR TO MSECOND |
TIMESTAMP - TIMESTAMP TIMESTAMP - DATE | INTERVAL DAY TO MSECOND |
(<Value> - <Value>) <Interval Type>
Expression | Interval Type |
DATE - DATE | YEAR MONTH YEAR TO MONTH DAY |
TIME - TIME | HOUR HOUR TO MINUTE HOUR TO SECOND HOUR TO MSECOND MINUTE MINUTE TO SECOND MINUTE TO MSECOND SECOND SECOND TO MSECOND MSECOND |
TIMESTAMP - TIMESTAMP TIMESTAMP - DATE | YEAR MONTH YEAR TO MONTH DAY DAY TO HOUR DAY TO MINUTE DAY TO SECOND DAY TO MSECOND HOUR HOUR TO MINUTE HOUR TO SECOND HOUR TO MSECOND MINUTE MINUTE TO SECOND MINUTE TO MSECOND SECOND SECOND TO MSECOND MSECOND |
-- The following uses the subtraction -- operator to show all customers that -- have not ordered within the last 12 -- months SELECT * FROM Customers WHERE (CURRENT_DATE-LastOrderDate) MONTH > 12
Deviation | Details |
None |
This web page was last updated on Thursday, November 16, 2023 at 10:39 AM | Privacy PolicySite Map © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |