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 4081852
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T18:06:52+00:00 2026-05-20T18:06:52+00:00

So mysql has a time(type) in which it has a 24 hour clock stored

  • 0

So mysql has a time(type) in which it has a 24 hour clock stored that can ouput time in am/pm format with the mysql function date_format(). The only problem is that when the user doesnt select the time, the value that stores in the mysql database is 00:00:00 which turns out to be 12:00am when i echo it with php. So how would i frame it so it can tell a difference between a null value and 00:00:00 which is 12:00am? (Btw, i try inserting null into the time column, turns out to be 00:00:00, which is 12:00am).

  • 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-05-20T18:06:52+00:00Added an answer on May 20, 2026 at 6:06 pm

    So how would i frame it so it can tell
    a difference between a null value and
    00:00:00 which is 12:00am? (Btw, i try
    inserting null into the time column,
    turns out to be 00:00:00, which is
    12:00am).

    Make the column nullable. (Remove the NOT NULL constraint.)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Mysql has two types that can hold boolean data, bit and bool. Bit(1) seems
My MySQL database has date of birth stored in the format yyyy-mm-dd, how do
I have a mysql database that has text stored in it with non encoded
After running the following SQL statements, you will see that, MySQL has automatically created
We need to redo a database in MySQL that has been already done on
the mysql table below has two columns. how do i select only those rows
I have mysql table that has a column that stores xml as a string.
I have a MySQL table which has a product_id field (big integer) 1102330008 1102330025
I have a huge MySQL table which has its rows encoded in UTF-8 twice.
I have a function that loops through different types of listings pulled from MySQL

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.