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

SNOW-1507519: Support column_order="name" based inserts #1844

Closed
sfc-gh-pkommini opened this issue Jun 27, 2024 · 5 comments
Closed

SNOW-1507519: Support column_order="name" based inserts #1844

sfc-gh-pkommini opened this issue Jun 27, 2024 · 5 comments
Assignees
Labels
feature New feature or request local testing Local Testing issues/PRs status-triage_done Initial triage done, will be further handled by the driver team

Comments

@sfc-gh-pkommini
Copy link

What is the current behavior?

While execute this code:

my_temp_table.write.mode("append").save_as_table(
            [self.database, self.schema, self.table],
            column_order='name',
        )

We get this error:

NotImplementedError: [Local Testing] Inserting data into table by matching columns is not supported.

What is the desired behavior?

I want the insert to happen.

How would this improve snowflake-snowpark-python?

This would allow us to insert without specifying column list.

References, Other Background

We need this for an internal project.

@sfc-gh-pkommini sfc-gh-pkommini added the feature New feature or request label Jun 27, 2024
@sfc-gh-pkommini sfc-gh-pkommini changed the title Support column_order="name" based inserts Support for column_order="name" based inserts Jun 27, 2024
@github-actions github-actions bot changed the title Support for column_order="name" based inserts SNOW-1507519: Support column_order="name" based inserts Jun 27, 2024
@sfc-gh-aling sfc-gh-aling added the local testing Local Testing issues/PRs label Jun 27, 2024
@sfc-gh-sghosh sfc-gh-sghosh self-assigned this Jun 28, 2024
@sfc-gh-sghosh
Copy link

Hello @sfc-gh-pkommini ,

Thanks for raising the issue.
This is working fine without local_testing. The issue is only with local_testing.
We will work on eliminating it.

Regards,
Sujan

@sfc-gh-sghosh sfc-gh-sghosh added the status-triage_done Initial triage done, will be further handled by the driver team label Jun 28, 2024
@mraraujo
Copy link

This would also be meaningful for us, especially related to inserts on tables with autoincrement columns.

@sfc-gh-pkommini
Copy link
Author

@sfc-gh-sghosh Started a PR for this feature #1854

@sfc-gh-aling
Copy link
Contributor

PR merged: #1872, it will be included in our next release

@sfc-gh-aling
Copy link
Contributor

closing the issue as the feature is released in v1.20.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request local testing Local Testing issues/PRs status-triage_done Initial triage done, will be further handled by the driver team
Projects
None yet
Development

No branches or pull requests

6 participants