On 6.6.2013 19:33, Michael Bayer wrote:
On Jun 6, 2013, at 12:56 PM, Ladislav Lenart lenart...@volny.cz wrote:
Hello.
I have already solved the issue by using subquery:
SELECT
t.id AS t_id,
t.rownum AS t_rownum
FROM (
SELECT
FROM
foo.id AS id,
Hello.
I am trying to adapt WindowedRangeQuery recipe
http://www.sqlalchemy.org/trac/wiki/UsageRecipes/WindowedRangeQuery
I have just stumbled upon the following issue:
def _q_windows(self, window_size):
q = self._query.with_entities(
self._column,
Hello.
I have already solved the issue by using subquery:
SELECT
t.id AS t_id,
t.rownum AS t_rownum
FROM (
SELECT
FROM
foo.id AS id,
row_number() OVER (ORDER BY foo.id) AS rownum
) AS t
WHERE rownum % 50 = 1
I have just tried your suggestion about using HAVING
On Jun 6, 2013, at 12:56 PM, Ladislav Lenart lenart...@volny.cz wrote:
Hello.
I have already solved the issue by using subquery:
SELECT
t.id AS t_id,
t.rownum AS t_rownum
FROM (
SELECT
FROM
foo.id AS id,
row_number() OVER (ORDER BY foo.id) AS rownum
) AS
Am 06.06.2013, 18:56 Uhr, schrieb Ladislav Lenart lenart...@volny.cz:
Hello.
I have already solved the issue by using subquery:
SELECT
t.id AS t_id,
t.rownum AS t_rownum
FROM (
SELECT
FROM
foo.id AS id,
row_number() OVER (ORDER BY foo.id) AS rownum
) AS t
WHERE