I'm a bit confused about the definition of single-row inserts vs. bulk inserts in Snowflake.
I want to understand what is happening under the hood when executing insert statements in Snowflake, specifically with respect to micropartitions. It's my understanding that bulk inserting new records into a table has the same effect on the micropartitions of that table as a COPY INTO statement. However, when loading the same amount of records into a table via single-row inserts, we increase the number of micropartitions (e.g. first insert creates a single row partition, second insert creates a new 2 row partition, etc.)
My question is what exactly is a bulk insert?
insert into table1 select * from table2
^^ seems like a bulk insert
insert into table1 values (val1, val2), (val3, val4)
^^ this inserts two rows of data so is that considered bulk? If not why not?
insert into table1 values (val1, val2)
^^ pretty sure this is a single row insert
Thanks for any help!
“Bulk insert” does not have a technical definition, it is just generally used to mean inserting more than one record in a single statement.