Sign inTry Free
  • Getting Started with SingleStoreDB Cloud
    • Connect to Your Workspace
      • Create a Database
        • Integrate with SingleStoreDB Cloud
          • Load Data
            • Query Data
              • Manage Data
                • Developer Resources
                  • User and Workspace Administration
                    • Security
                      • Reference
                        • Configuration Reference
                          • Information Schema Reference
                            • SQL Reference
                              • SQL Command Syntax
                              • SQL Commands List
                              • SQL Functions List
                              • Comparison Operators and Functions
                                • Database Object Case-Sensitivity
                                • Data Types
                                  • Character Encoding
                                    • Operations that Take Either a Database or a Workspace Level Lock
                                      • User-Defined Variables
                                        • Restricted Keywords
                                          • Aggregate Functions
                                            • Workspace Management Commands
                                              • Code Generation Functions
                                                • Conditional Functions
                                                  • Data Definition Language DDL
                                                    • Data Manipulation Language DML
                                                      • Date and Time Functions
                                                        • ADDTIME
                                                        • CONVERT_TZ
                                                        • CURRENT_DATE And CURDATE
                                                        • CURRENT_TIME And CURTIME
                                                        • CURRENT_TIMESTAMP
                                                        • DATE
                                                        • DATEDIFF
                                                        • DATE_ADD
                                                        • DATE_FORMAT
                                                        • DATE_SUB
                                                        • DATE_TRUNC
                                                        • DAY
                                                        • DAYNAME
                                                        • DAYOFWEEK
                                                        • DAYOFYEAR
                                                        • EXTRACT
                                                        • FROM_DAYS
                                                        • FROM_UNIXTIME
                                                        • GET_FORMAT
                                                        • HOUR
                                                        • LAST_DAY
                                                        • LOCALTIMESTAMP
                                                        • MICROSECOND
                                                        • MINUTE
                                                        • MONTH
                                                        • MONTHNAME
                                                        • MONTHS_BETWEEN
                                                        • NOW
                                                        • QUARTER
                                                        • SECOND
                                                        • SEC_TO_TIME
                                                        • STR_TO_DATE
                                                        • TIME
                                                        • TIMEDIFF
                                                        • TIMESTAMP
                                                        • TIMESTAMPADD
                                                        • TIMESTAMPDIFF
                                                        • TIME_FORMAT
                                                        • TIME_TO_SEC
                                                        • TO_CHAR
                                                        • TO_DATE
                                                        • TO_DAYS
                                                        • TO_SECONDS
                                                        • TO_TIMESTAMP
                                                        • TRUNC
                                                        • UNIX_TIMESTAMP
                                                        • UTC_DATE
                                                        • UTC_TIME
                                                        • UTC_TIMESTAMP
                                                        • WEEK
                                                        • WEEKDAY
                                                        • YEAR
                                                      • Distinct Count Estimation Functions
                                                        • Full-Text Search Functions
                                                          • Geospatial Functions
                                                            • Identifier Generation Functions
                                                              • Information Functions
                                                                • JSON Functions
                                                                  • Numeric Functions
                                                                    • Operational Commands
                                                                      • Pipelines Commands
                                                                        • Procedural SQL Reference
                                                                          • Regular Expression Functions
                                                                            • Resource Pool Commands
                                                                              • Security Management Commands
                                                                                • SHOW Commands
                                                                                  • String Functions
                                                                                    • Time Series Functions
                                                                                      • Vector Functions
                                                                                        • Window Functions
                                                                                        • Troubleshooting Reference
                                                                                          • System Databases
                                                                                          • Master Aggregator High Availability After Availability Zone Failure
                                                                                          • Data API
                                                                                            • Management API
                                                                                              • Code Engine - Powered by Wasm
                                                                                                • SingleStore Kai
                                                                                                • Release Notes
                                                                                                  • Support
                                                                                                    • Glossary
                                                                                                    1. Cloud
                                                                                                    2. /
                                                                                                    3. ...
                                                                                                    4. /
                                                                                                    5. Date and Time Functions

                                                                                                    Date and Time Functions

                                                                                                    In this section

                                                                                                    • ADDTIME
                                                                                                    • CONVERT_TZ
                                                                                                    • CURRENT_DATE And CURDATE
                                                                                                    • CURRENT_TIME And CURTIME
                                                                                                    • CURRENT_TIMESTAMP
                                                                                                    • DATE
                                                                                                    • DATEDIFF
                                                                                                    • DATE_ADD
                                                                                                    • DATE_FORMAT
                                                                                                    • DATE_SUB
                                                                                                    • DATE_TRUNC
                                                                                                    • DAY
                                                                                                    • DAYNAME
                                                                                                    • DAYOFWEEK
                                                                                                    • DAYOFYEAR
                                                                                                    • EXTRACT
                                                                                                    • FROM_DAYS
                                                                                                    • FROM_UNIXTIME
                                                                                                    • GET_FORMAT
                                                                                                    • HOUR
                                                                                                    • LAST_DAY
                                                                                                    • LOCALTIMESTAMP
                                                                                                    • MICROSECOND
                                                                                                    • MINUTE
                                                                                                    • MONTH
                                                                                                    • MONTHNAME
                                                                                                    • MONTHS_BETWEEN
                                                                                                    • NOW
                                                                                                    • QUARTER
                                                                                                    • SECOND
                                                                                                    • SEC_TO_TIME
                                                                                                    • STR_TO_DATE
                                                                                                    • TIME
                                                                                                    • TIMEDIFF
                                                                                                    • TIMESTAMP
                                                                                                    • TIMESTAMPADD
                                                                                                    • TIMESTAMPDIFF
                                                                                                    • TIME_FORMAT
                                                                                                    • TIME_TO_SEC
                                                                                                    • TO_CHAR
                                                                                                    • TO_DATE
                                                                                                    • TO_DAYS
                                                                                                    • TO_SECONDS
                                                                                                    • TO_TIMESTAMP
                                                                                                    • TRUNC
                                                                                                    • UNIX_TIMESTAMP
                                                                                                    • UTC_DATE
                                                                                                    • UTC_TIME
                                                                                                    • UTC_TIMESTAMP
                                                                                                    • WEEK
                                                                                                    • WEEKDAY
                                                                                                    • YEAR

                                                                                                    Last modified: November 17, 2022

                                                                                                    Was this article helpful?

                                                                                                    Query Plan Operations
                                                                                                    ADDTIME

                                                                                                    Product

                                                                                                    • Product Overview
                                                                                                    • Solutions
                                                                                                    • Pricing
                                                                                                    • Support

                                                                                                    Community

                                                                                                    • Forums
                                                                                                    • Developer Hub
                                                                                                    • Events
                                                                                                    • Training

                                                                                                    Company

                                                                                                    • Contact Us
                                                                                                    • Blog
                                                                                                    • Careers
                                                                                                    • SingleStore Connect

                                                                                                    This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

                                                                                                    • © SingleStore
                                                                                                    • |

                                                                                                    • Privacy Policy
                                                                                                    • |

                                                                                                    • Terms of Service
                                                                                                    • |

                                                                                                    • Legal Terms and Conditions

                                                                                                    Was this article helpful?