Django create query set

Last updated 1 year, 3 months ago | 456 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")