Skip to content

Fix ranged load from MySQL does not load the last record. #1203

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

Merged
merged 1 commit into from
Aug 31, 2020

Conversation

lukesilvia
Copy link
Contributor

Problem

I tried to load MySQL tables into PostgreSQL with rows per range option. The following is full with options.

WITH workers = 8, concurrency = 2, multiple readers per thread, rows per range = 50000, batch rows = 10000, prefetch rows = 10000

But at some tables, the last record was not copied to PostgreSQL.

Cause

where clause for ranged load seems to ignore the last record (or the record has max primary key).

(let ((sql (format nil "~a WHERE `~a` >= ~a AND `~a` < ~a"

Thank you for checking my pull request.

@dimitri dimitri merged commit 48d8ed0 into dimitri:master Aug 31, 2020
@dimitri
Copy link
Owner

dimitri commented Aug 31, 2020

Thanks a lot for your contribution @lukesilvia !

@bendavies
Copy link

hi @dimitri,
Any chance of getting a release with this fix included?

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants