working of insert_many vs multiple single inserts #453
Answered
by
billy1624
vikigenius
asked this question in
Q&A
-
I want to know about the optimization of insert_many. How is it implemented? Does it work as a single insert with multiple values like SQLITE allows
or does it work as multiple insert statements, which is presumably slower? |
Beta Was this translation helpful? Give feedback.
Answered by
billy1624
Jan 12, 2022
Replies: 1 comment
-
Hey @vikigenius, just like what you have said. sea-orm/src/entity/base_entity.rs Lines 384 to 406 in 6120d82 |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
tyt2y3
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hey @vikigenius, just like what you have said.
insert_many
will construct SQL statement like that. And it will be sent to the database once only.sea-orm/src/entity/base_entity.rs
Lines 384 to 406 in 6120d82