not a list, causing "can only concatenate list"
TypeError when combined with other clauses.
+ - Fixed incorrect usage of "," in over() clause
+ being placed between the "partition" and "order by"
+ clauses. [ticket:2134]
+
- engine
- The C extension is now enabled by default on CPython
2.x with a fallback to pure python if it fails to
x += "PARTITION BY %s" % \
over.partition_by._compiler_dispatch(self, **kwargs)
if over.order_by is not None:
- x += ", "
+ x += " "
if over.order_by is not None:
x += "ORDER BY %s" % \
over.order_by._compiler_dispatch(self, **kwargs)
partition_by=[table1.c.name],
order_by=[table1.c.description]
),
- "row_number() OVER (PARTITION BY mytable.name, "
+ "row_number() OVER (PARTITION BY mytable.name "
"ORDER BY mytable.description)"
)
self.assert_compile(
partition_by=table1.c.name,
order_by=table1.c.description
),
- "row_number() OVER (PARTITION BY mytable.name, "
+ "row_number() OVER (PARTITION BY mytable.name "
"ORDER BY mytable.description)"
)
+ self.assert_compile(
+ func.row_number().over(
+ partition_by=table1.c.name,
+ order_by=[table1.c.name, table1.c.description]
+ ),
+ "row_number() OVER (PARTITION BY mytable.name "
+ "ORDER BY mytable.name, mytable.description)"
+ )
+
self.assert_compile(
select([func.row_number().over(
order_by=table1.c.description