Skip to content
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

🐛 Source MySQL: java.sql.SQLException: DAY_OF_MONTH #15161

Closed
marcosmarxm opened this issue Aug 1, 2022 · 13 comments
Closed

🐛 Source MySQL: java.sql.SQLException: DAY_OF_MONTH #15161

marcosmarxm opened this issue Aug 1, 2022 · 13 comments
Assignees
Labels
area/connectors Connector related issues connectors/source/mysql team/db-dw-sources Backlog for Database and Data Warehouse Sources team type/bug Something isn't working zendesk

Comments

@marcosmarxm
Copy link
Member

This Github issue is synchronized with Zendesk:

Ticket ID: #1724
Priority: normal
Group: Community Assistance Engineer
Assignee: Nataly Merezhuk

Original ticket description:

  • Is this your first time deploying Airbyte?: Yes
  • Memory / Disk / CPU: 16Gb ram, 50gb, 8core / 16 logical processor
  • Deployment: Docker Desktop
  • Airbyte Version: 0.39.37-alpha
  • Source name/version: MySQL 0.5.6
  • Destination name/version: Postgres 14
  • Step: Issue is happening on sync
  • Description: I have two connectors with mysql and both keep failing either with sql exception of MONTH or YEAR for the either.

logs-13.txt (1.0 MB)

[Discourse post]

@marcosmarxm
Copy link
Member Author

Comment made from Zendesk by Marcos Marx on 2022-07-27 at 08:41:

I did additional tests by creating a view from the original table without date related fields (strings) and sync was successful, there seems to be an issue with one of the date columns regarding to the data maybe.

Not sure how and what to find.

[Discourse post]

@marcosmarxm
Copy link
Member Author

Comment made from Zendesk by Nataly Merezhuk on 2022-07-27 at 13:19:

Hello and welcome to the Airbyte community, @antonapua! It looks like you may be passing the wrong format in date related fields. Could you try using an instance of LocalDate instead of a string?

@marcosmarxm
Copy link
Member Author

Comment made from Zendesk by Marcos Marx on 2022-07-28 at 04:20:

Hi @natalyjazzviolin,

I am not sure what LocalDate you’re referring to, is that Java? I don’t have access to change the existing mysql table not control over what data goes into it.

I did create a mysql view table and tried to apply CAST as DATETIME() however, I still encountered the same issue.

[Discourse post]

@marcosmarxm
Copy link
Member Author

Comment made from Zendesk by Marcos Marx on 2022-07-28 at 07:38:

@marcosmarxm
Copy link
Member Author

Comment made from Zendesk by Marcos Marx on 2022-07-28 at 08:33:

applied zerodatetimebehavior=Converttonull still having the same issue
logs-99.txt (2.6 MB)

[Discourse post]

@marcosmarxm
Copy link
Member Author

Comment made from Zendesk by Nataly Merezhuk on 2022-08-01 at 15:29:

From the latest logs it looks like the problem is now in DAY_OF_MONTH. I found another related issue that's been resolved:
#5070

I think the best course of action is to escalate this to GitHub, so I'lll do that next!

@natalyjazzviolin natalyjazzviolin changed the title MSQL Source SQL Exception Month/Year Source MySQL: java.sql.SQLException: DAY_OF_MONTH Aug 1, 2022
@natalyjazzviolin natalyjazzviolin changed the title Source MySQL: java.sql.SQLException: DAY_OF_MONTH 🐛 Source MySQL: java.sql.SQLException: DAY_OF_MONTH Aug 1, 2022
@natalyjazzviolin natalyjazzviolin added the type/bug Something isn't working label Aug 1, 2022
@marcosmarxm
Copy link
Member Author

Comment made from Zendesk by Nataly Merezhuk on 2022-08-01 at 15:32:

Please feel free to add any details here:
#15161

@antonapua
Copy link

Identified issue where date value had 00 as day. wish this was ignored or converted to null.

@grishick
Copy link
Contributor

@marcosmarxm this was likely fixed fairly recently. Can we ask the user to retry?

@marcosmarxm
Copy link
Member Author

Comment made from Zendesk by Nataly Merezhuk on 2022-08-30 at 18:53:

Hello again, @antonapua. Could you retry - looks like the issue might have been fixed!

@grishick grishick added the team/db-dw-sources Backlog for Database and Data Warehouse Sources team label Sep 27, 2022
@akashkulk akashkulk self-assigned this Sep 30, 2022
@akashkulk
Copy link
Contributor

Closing this out for now, since no issues were reported by the user after the fix

@octav-s
Copy link

octav-s commented Aug 8, 2023

Still getting the issue in August 2023. I believe it is related to some dates being null. I've triead any and all parameters for the JDBC connector, it made no difference. I've checked the worker log and besides the DAY_OF_MONTH error, it is also showing another error, "c.n.s.DateTimeValidator(tryParse):82 - Invalid date-time: No zone offset information found". I've chacked all date and datetime fields, the values are either valid dates or NULL values.
worker_log.txt
f7199418_cea5_41e1_a66c_3e72df231d5f_job_8_attempt_3.txt
f7199418_cea5_41e1_a66c_3e72df231d5f_job_8_attempt_2.txt
f7199418_cea5_41e1_a66c_3e72df231d5f_job_8_attempt_1.txt

@octav-s
Copy link

octav-s commented Aug 8, 2023

PS: I've been getting the same error, DAY_OF_MONTH, in AWS Glue as well. I have not been able to figure out why it happens.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/connectors Connector related issues connectors/source/mysql team/db-dw-sources Backlog for Database and Data Warehouse Sources team type/bug Something isn't working zendesk
Projects
None yet
Development

No branches or pull requests

8 participants
@grishick @antonapua @marcosmarxm @octav-s @natalyjazzviolin @octavia-squidington-iii @akashkulk and others