-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix zero timestamp #1
Conversation
|
Where does this come from? |
no idea, maybe some of the files in .github folder? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Noting here that we went over this in a video call and confirmed that timestamp 1970-01-01 00:00:00
isn't valid for MySQL. The lowest value you can put seems to be 1970-01-01 00:00:01
.
@agonzale34 , good catch. Regarding contributing this upstream, it appears this problem has been fixed because they updated the version of the It used to be case MYSQL_TYPE_TIMESTAMP:
n = 4
t := binary.LittleEndian.Uint32(data)
if t == 0 {
v = formatZeroTime(0, 0)
} else {
// ... |
@pbitty Thanks for going above a beyond with that investigation. I really wish we could use this version with our AWS RDS cluster, sadly the tx_isolation error won't let us use the version: |
I realize that. I just mean that I don't think we need to contribute this fix upstream - it looks like it's been fixed. It was easy for me to find this because I've worked a lot on our |
Perfect, this PR is just internally for us, while they main project update the issues with the rds. |
Description
This PR contains bugfix for timestamp zero issue we are facing when migrating tables that get new inserts, with 0 timestamp value, which get a wrong format.
script/cibuild
returns with no formatting errors, build errors or unit test errors.