Monday , November 25 2024

ISDATE Function in SQL Server(TSQL)

You can check the expression is a valid date, time or datetime value using ISDATE Function. This function’s return type is int.

Before using this function, be aware that;

  • The datetime value range is between 1753-01-01 and 9999-12-31
  • The date value range is between 0001-01-01 and 9999-12-31

You can control the expression with IF Clause and ISDATE function as follows. You can find detailed information about SET DATEFORMAT command in the article named “SET DATEFORMAT in SQL Server(TSQL)

Loading

About dbtut

We are a team with over 10 years of database management and BI experience. Our Expertises: Oracle, SQL Server, PostgreSQL, MySQL, MongoDB, Elasticsearch, Kibana, Grafana.

Leave a Reply

Your email address will not be published. Required fields are marked *