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

[master < T914] Add command NULLIF for identifying nulls in LOAD CSV #914

Merged
merged 44 commits into from
Jun 21, 2023

Conversation

Josipmrden
Copy link
Contributor

@Josipmrden Josipmrden commented May 3, 2023

The NULLIF command used in LOAD CSV enables for users to parse the LOAD CSV in a way which treats characters which have the identical character sequence as the NULLIF character as nulls.

Usage:
LOAD CSV FROM './file.csv' WITH HEADER NULLIF 'N/A' AS row ...

[master < Task] PR

  • Check, and update documentation if necessary
  • Provide the full content or a guide for the final git message

To keep docs changelog up to date, one more thing to do:

  • Write a release note here
    Added NULLIF command in the LOAD CSV clause to specify a character sequence which will treat identical values in the csv file as nulls
  • Tag someone from docs team in the comments

@Josipmrden Josipmrden changed the title [master < T914] Ignore empty strings in LOAD CSV [master < T914] Add identifier for NULL in LOAD CSV Jun 14, 2023
@Josipmrden Josipmrden changed the title [master < T914] Add identifier for NULL in LOAD CSV [master < T914] Add command NULLIF for identifying nulls in LOAD CSV Jun 14, 2023
@Josipmrden Josipmrden marked this pull request as ready for review June 14, 2023 09:02
@Josipmrden Josipmrden requested review from antoniofilipovic and removed request for as51340 and antoniofilipovic June 14, 2023 09:04
@antoniofilipovic
Copy link
Collaborator

antoniofilipovic commented Jun 20, 2023

I think you need to add the keyword nullif on src/query/frontend/stripped_lexer_constants.hpp as mentioned on this Notion page.

Copy link
Collaborator

@antoniofilipovic antoniofilipovic left a comment

Choose a reason for hiding this comment

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

Small change, otherwise looks good

@Josipmrden Josipmrden merged commit 05cc35b into master Jun 21, 2023
6 checks passed
@Josipmrden Josipmrden deleted the T630-load-csv-ignore-empty-strings branch June 21, 2023 12:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

[BUG] LOAD CSV does not parse empty values as null but as empty strings
3 participants