﻿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
13976	Admin view with relations (ForeignKey or ManyToMany) does not limit number of entries in document	yngve@…	nobody	"When opening for view or edit a record in the admin view of a model with a ForeignKey or ManyToMany relation to another table, the view lists '''all''' entries from the other table in the dropdown/selection box, no matter how many entries there are in that table.

The result is that if the reference table contain hundreds of thousands, or millions of entries, the record cannot be viewed, or edited, in the admin view, because it tries to generate a document that may run into Gigabytes, as well as require accessing each record in that table to get information about it.

My suggestion is that the admin view should restrict the number of elements in such automatically generated dropdown/selection boxes to at most 100 elements, preferably less than 50, and provide an alternative selection mechanism if the number of elements exceeds this limit.

The admin view may not be intended for such cases, but I would suggest that it ought to be able to handle such situations gracefully.

Another area where such numbers cause problems is when deleting a record that references, or is referenced by, large numbers of records."		closed	Uncategorized	1.1		invalid		Henrique C. Alves	Unreviewed	0	0	0	0	0	0
