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

Could a batchSize parameter be added to insertTable? #297

Open
katy-sadowski opened this issue Dec 9, 2024 · 4 comments
Open

Could a batchSize parameter be added to insertTable? #297

katy-sadowski opened this issue Dec 9, 2024 · 4 comments

Comments

@katy-sadowski
Copy link

Would it be possible to add a batchSize parameter (like the one in dbWriteTable) to insertTable?

Use case: I'd like to provide the option to specify a tempEmulationSchema, and to insert data in batches.

@schuemie
Copy link
Member

The aim of the insertTable() function is to work with as little user hand-holding across all supported platforms. It currently uses a hard-coded batch size of 10,000 rows. Is this not working for you?

@katy-sadowski
Copy link
Author

ah! i missed that! that works for me, though maybe couldn't hurt to add it as a param with default value 10000 for more flexibility/clarity?

@schuemie
Copy link
Member

Well, the behavior can actually be different depending on the database platform, and of course it is a whole different story when you enable bulk loading. The insertTable() function should just be smart enough to figure out how to upload your data. If you're running into cases where it's not, let me know and we can fix the behavior.

@katy-sadowski
Copy link
Author

makes sense. it worked like a charm as-is in Snowflake - i hadn't even tried it before because i thought it wasn't possible to specify the batch size and assumed the default was 1 😂 🤦

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

No branches or pull requests

2 participants