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

Fixes #2932: The apoc.import.csv skipLines config doesn't work correctly #2984

Merged
merged 2 commits into from
Jun 24, 2022

Conversation

vga91
Copy link
Collaborator

@vga91 vga91 commented Jun 15, 2022

Fixes #2932

  • Leverage on CsvReader to skipLines,
    because CountingReader.skip(n) calls java.io.FilterReader.skip(n), which skip characters instead of lines.
    removing the CountingReader.skip is not a breaking-change because by default is skip(0), so the CountingReader skip nothing actually.

  • changed deprecated API CSVReader to CSVReaderBuilder

@Lojjs Lojjs self-assigned this Jun 17, 2022
Copy link
Contributor

@Lojjs Lojjs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you have mixed up two comments, otherwise it looks great

Comment on lines 195 to 198
// skip header and another one
testSkipLine(1L, 2);

// skip only-header (default config)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume these two comments should switch place?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vga91 Thanks for fixing, looks good now!

@vga91 vga91 merged commit c94a817 into neo4j-contrib:4.4 Jun 24, 2022
vga91 added a commit to vga91/neo4j-apoc-procedures that referenced this pull request Jun 24, 2022
vga91 added a commit to vga91/neo4j-apoc-procedures that referenced this pull request Jun 24, 2022
vga91 added a commit to vga91/neo4j-apoc-procedures that referenced this pull request Jun 29, 2022
vga91 added a commit that referenced this pull request Jul 5, 2022
vga91 added a commit that referenced this pull request Jul 5, 2022
gem-neo4j pushed a commit to gem-neo4j/neo4j-apoc-procedures that referenced this pull request Jul 12, 2022
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.

The apoc.import.csv skipLines config doesn't work correctly
2 participants