Django create query set

Last updated 9 months, 3 weeks ago | 339 views 75     5

Tags:- Django

Django | Insert record in database using create() function



Create function create a new object with the given `kwargs`, saving it to the database and returning the created object. It creates an object and saving it, all in one step.

Person.objects.create(first_name="David", last_name="Brown")