Purpose
This function adds a specified number of hours to a timestamp.
Syntax
add_hour::=
                                                                         
                                                                    
Usage Notes
- Decimals are rounded before adding the number.
- For data type TIMESTAMP WITH LOCAL TIME ZONEthis function is calculated internally within UTC before the result is transformed to the session time zone.
Example
Copy
                                                                
                                                            
                                                            SELECT ADD_HOURS(TIMESTAMP '2000-01-01 00:00:00', 1) AH1,
       ADD_HOURS(TIMESTAMP '2000-01-01 12:23:45', -1) AH2;Result
| AH1 | AH2 | 
| 2000-01-01 01:00:00.000000 | 2000-01-01 11:23:45.000000 |