English 中文(简体)
缩略语
原标题:Execute Multiple SQL Insert Statements in parallel in Snowflake

我有一个问题,即它如何在Snowflake同时执行数份卡片声明时发挥作用。

例如,如果我执行10次,在10个不同的表格上加上相同的基表,这些表格是否将同时装满?

问题回答

你可以同时进行提问,只增加“和”符号。

例如:

以下陈述将同时提交所有上述询问,以防震。 如果在任何询问中都遇到任何错误,则不会退出。

snowsql -o 标识:级 - 退出: “选择1;>select * from SNOWSQLTABLE;>select 2;>>insert into TABLE Value (1)>select * from SNOWLTABLE;>select 5;”

以下陈述将导致在发现任何错误时提出询问,然后撤回。

snowsql -o 标识:级 - 退出:_on_error=true -q “select 1;select * from SNOWSQLTABLE;select 2;select 3;insert into SNOQSQLTABLE Value(1);select * from SNOWLTABLE;select 5;”

由于印本和加插说明仅以新的分部分写,它们可与其他制版同时操作或插入报表。

rel=“nofollow noreferer”>https://docs.snowflake.com/en/sql-vis/transactions.html

https://docs.snowflake.com/en/sql-vis/transactions.html#transaction-commands-and-Functions 指出,“Most INSERT和COPY声明只写了新的部分。 这些发言往往可以与其他INSERT和COPY业务平行进行。

I assume that statements cannot run in parallel when they want to insert into the same micro partition. Is that correct or is there another explanation why locks on INSERTs can happen?

I execute 10 insert statements on 10 different tables with the same base table - will the tables be loaded in parallel?

YES!

https://docs.snowflake.com

斯诺克的保险由多个仓库(混合资源)管理,或在一个仓库(一个有不止一组服务器的虚拟仓库)进行多功能管理。

rel=“nofollow noreferer” https://docs.snowflake.com/en/user-guide/warehouses-multicluster.html

我今天与客户一道工作,每天拥有数百万卡勒克的指挥部,他们拥有许多不同的仓库,这些仓库大多被安排到多功能的“一流”模式。

Specifically, for your question, it sounds like you have ten sessions connected, running inserts into ten tables via querying a single base table. I d probably begin my testing of this with one virtual warehouse, configured with a minimum of one cluster and a maximum of three or four, and then run tests and review the results.

我将使用的仓库的规模主要取决于问询的大小(选址部分),从中开始,可以审查各字的性能和问答计划,看看这是否适当。

When reviewing the plans, check for queuing time to see if perhaps three or four clusters isn t enough, it probably will be fine.

你的问询历史还将表明,在虚拟仓库里,你的问询会是哪些“分组——数目”。 这是检查有多少组群的运行情况(最大组群——数目)的一种方式,另一种是查看在网库中铺设的仓库,或执行“仓库”;指挥。

Some additional links that might help you:

https://www.snowflake.com/blog/auto-pl-snowflake-major-leap-forward-massively-con Current- Enterprises-applications/

https:// community.snowflake.com/s/article/Pdown-Snowflake-s-Automatic-Concurrency-Scaling-to-the- Test” rel=“nofollow noreferer”>https:// community.snowflake.com/s/article/Pdown-Snowflake-s-Automatic-Concurrency-Scaling-to-the- Test

https://support.snowflake.net/s/question/0D50Z00009T2Q LEXSA3/what-is-the-----pan-up-why-is-pan-out-for-concurrency-and-pan-up-is-for-ge-queries-rel=“nofollow noretinger”>https://support.snowake.net/s/question/D050Z00009T2Q2





相关问题
缩略语

我有一个问题,即它如何在Snowflake同时执行数份卡片声明时发挥作用。

热门标签