Skip to content

Conversation

yoavcloud
Copy link
Contributor

Added support for the Redshift variant of UNLOAD

#[derive(Debug, Clone, PartialEq, PartialOrd, Eq, Ord, Hash)]
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
#[cfg_attr(feature = "visitor", derive(Visit, VisitMut))]
pub struct PartitionBy {
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
pub struct PartitionBy {
pub struct UnloadPartitionBy {

Thinking since partitionby has meaning in other contexts?

/// NULL \[ AS \] 'null_string'
Null(String),
/// PARALLEL
Parallel(Option<bool>),
Copy link
Contributor

Choose a reason for hiding this comment

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

can we add a description here to mention the behavior of on/off?

Some(Keyword::GB) => Some(FileSizeUnit::GB),
_ => None,
};
CopyLegacyOption::RowGroupSize(FileSize { size, unit })
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we pull this out to a function like parse_file_size_unit() so that it can be reused?

} else {
None
};
let with = self.parse_options(Keyword::WITH)?;
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we add a test case that uses the WITH keyword in the syntax?

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.

2 participants