Re: '0000-00-00' is an invalid date
From: John Levine <johnl_at_taugh.com>
Date: Sun, 4 Feb 2018 18:04:23 -0000 (UTC)
Message-ID: <p57hv6$2un6$1_at_gal.iecc.com>
Date: Sun, 4 Feb 2018 18:04:23 -0000 (UTC)
Message-ID: <p57hv6$2un6$1_at_gal.iecc.com>
[Quoted] In article <p56vs9$1m6n$1_at_gioia.aioe.org> you write:
>I can SELECT * FROM `episodes` where `ending` = '0000-00-00'
>without error, but
>update`episodes` set `ending` = NULL
>where `ending` = '0000-00-00'
>gives me the error.
>
>any suggestions how to render the 'ending' field updatable?
[Quoted] Valid dates start at '1000-01-01', and I doubt that any of your episodes are more than 900 years old, so try this:
update `episodes` set `ending` = NULL where `ending` < '1200-01-01'
If you want to make sure those are the right ones, you can try this first:
select * from `episodes` where `ending` < '1200-01-01'
-- Regards, John Levine, johnl_at_iecc.com, Primary Perpetrator of "The Internet for Dummies", Please consider the environment before reading this e-mail. https://jl.lyReceived on Sun Feb 04 2018 - 19:04:23 CET