What does the bulk_create method do in Django?
Correct answer
B. Creates multiple objects in a single database query
17 views
B. Creates multiple objects in a single database query
17 views
bulk_create() creates multiple objects in a single database query: Book.objects.bulk_create([Book(...), Book(...)]). It is far faster than saving objects one at a time.
Note that it does not call each model's save() method or send the save signals.
For more solved questions like this one, see Computer Science MCQs on MCQsExam.com.
Not sure why the answer is B? Ask here and get an explanation.