Revision 3357
Added by Aaron Marcuse-Kubitza over 12 years ago
sql.py | ||
---|---|---|
1347 | 1347 |
@return The new table. |
1348 | 1348 |
''' |
1349 | 1349 |
new_table = sql_gen.suffixed_table(table, '_distinct') |
1350 |
distinct_on = filter(lambda c: not sql_gen.is_null(c), |
|
1351 |
map(sql_gen.remove_col_rename, distinct_on)) |
|
1350 | 1352 |
|
1351 | 1353 |
copy_table_struct(db, table, new_table) |
1352 | 1354 |
|
Also available in: Unified diff
sql.py: distinct_table(): Support literal values as column expressions. Filter out untyped NULLs because the type unknown can't be indexed.