Ticket #13017: sql_query.patch
File sql_query.patch, 1.4 KB (added by , 15 years ago) |
---|
-
query.py
1273 1273 to_col1, table2, from_col2, to_col2, opts, 1274 1274 target) 1275 1275 1276 int_alias = self.join((alias, table1, from_col1, to_col1), 1276 if alias == table1 and from_col1 == to_col1: 1277 alias = self.join((alias, table2, from_col2, to_col2), 1277 1278 dupe_multis, exclusions, nullable=True, 1278 1279 reuse=can_reuse) 1279 alias = self.join((int_alias, table2, from_col2, to_col2), 1280 joins.extend([alias]) 1281 else: 1282 int_alias = self.join((alias, table1, from_col1, to_col1), 1280 1283 dupe_multis, exclusions, nullable=True, 1281 1284 reuse=can_reuse) 1282 joins.extend([int_alias, alias]) 1285 alias = self.join((int_alias, table2, from_col2, to_col2), 1286 dupe_multis, exclusions, nullable=True, 1287 reuse=can_reuse) 1288 joins.extend([int_alias, alias]) 1283 1289 else: 1284 1290 # One-to-many field (ForeignKey defined on the target model) 1285 1291 if cached_data: