﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
35419	Add support for creating records from a queryset	Clemens Wolff	nobody	"For performing efficient inserts based on existing data, it would be great if Django could offer support for the ANSI SQL **INSERT INTO ... SELECT FROM ...**, perhaps something along the lines of the following snippet:

{{{
queryset = MyTable.objects.filter(field=value)
MyTable.objects.create_from(queryset)
}}}

Currently this type of insertion is only possible by bypassing the ORM or by evaluating the queryset and then doing a bulk_create. The former is undesirable for maintainability and the latter is inefficient as it executes 2 queries and potentially transfers a lot of data over the network.

The feature has been requested in a few other places such as [https://stackoverflow.com/questions/70888534/ StackOverflow] and the [https://forum.djangoproject.com/t/14648/ Django Forum] so I figured that it would be a good idea to open an actual ticket for it.

If the feature request were to be accepted, I can work on a patch for it if provided with some high-level guidance."	New feature	closed	Database layer (models, ORM)		Normal	wontfix			Unreviewed	0	0	0	0	0	0
