[OSM-dev] Proposed database improvement
Nick Hill
nick at nickhill.co.uk
Thu Aug 31 17:52:42 BST 2006
Nick Hill wrote:
> res = call_sql {"SELECT DISTINCTROW * FROM ( SELECT id, node_a, node_b,
> tags FROM current_segments where node_a IN #{cbuff} and visible = true
> UNION SELECT id, node_a, node_b, tags FROM current_segments where node_b
> IN #{cbuff} and visible = true) as a ORDER BY id ASC #{timeclause}"}
Clauses in wrong order. Should be:
res = call_sql {"SELECT DISTINCTROW * FROM ( SELECT id, node_a, node_b,
tags FROM current_segments where node_a IN #{cbuff} and visible = true
UNION SELECT id, node_a, node_b, tags FROM current_segments where node_b
IN #{cbuff} and visible = true) as a #{timeclause} ORDER BY id ASC"}
More information about the dev
mailing list