Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7918429
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T15:30:22+00:00 2026-06-03T15:30:22+00:00

Good day everyone! I am using the T-SQL ISDATE() function with a date column

  • 0

Good day everyone!

I am using the T-SQL ISDATE() function with a date column as argument to filter out bad dates; the problem is the ISDATE function will return zero when it comes across a NULL value.

So with the example below; valid data in the table will be left out of the result set if there is a null for their dates. How can I remedy this so that I can get valid dates but also retrieve records with no dates? I need the records with no dates as well, I only need to remove those with bad dates, example, incomplete dates or dates missing characters.

Example:

SELECT * FROM EXAMPLE WHERE ISDATE(MAYDATE) <> 0

Thanks my friends!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T15:30:24+00:00Added an answer on June 3, 2026 at 3:30 pm

    You could either use the ISNULL function, to replace the NULL value with a valid date value that is just used by the ISDATE function. Here are two examples:

    SELECT * FROM EXAMPLE WHERE ISDATE(ISNULL(MAYDATE, '1/1/1900')) <> 0
    SELECT * FROM EXAMPLE WHERE ISDATE(ISNULL(MAYDATE, GETDATE())) <> 0
    

    Or just check to see if the the value is NULL

    SELECT * FROM EXAMPLE WHERE (ISDATE(MAYDATE) <> 0) OR (MAYDATE IS NULL)
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Good day everyone! I have a problem regarding my date. It needs to be
Good day everyone, I am building a page in ASP.NET, and using Master Pages
Good day everyone. I have been having the same problem all day at work
Good day, I am using CacheFilter to filter a certain path to my server
Good day everyone. I have a question about making and using derived classes of
Good day, everyone. I'm using sableCC , and it takes as input a Reader
Good day everyone, i hope you are all happy and healthy :) My problem
Good day everyone. This problem was part of another one which it as been
Good day everyone. I am working on a Firefox extension, and I want to
Good Day Everyone... Apparently, I'm not setting-up impersonation correctly for my WCF service. I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.