﻿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
25064	Join.as_sql() emits invalid SQL if get_joining_columns() returns an empty tuple	Alex Hill	nobody	"`Join.as_sql()` gets its join conditions from two places: the `get_joining_columns()` and `get_extra_restrictions()`.

The SQL for extra restrictions is unconditionally prefixed with `AND`, which means invalid SQL is emitted if no joining columns are specified. The fix to make the `AND` conditional is a one-liner and allows users to override the default join conditions instead of adding to them."	Bug	new	Database layer (models, ORM)	1.8	Normal				Unreviewed	0	0	0	0	0	0
