On 2006-01-15 15:21, Tom Lane wrote:
Really? The FULL JOIN condition using ~ is the source of the failure, and I'd
be quite surprised if changing WHERE makes it work.
Works fine:
EXPLAIN SELECT count(*) FROM "Extra" FULL JOIN "GeoRestrict" ON
callsign ~ pattern WHERE geo_region =
4;
QUERY
PLAN
---------------------------------------------------------------------------------
Aggregate (cost=1934.02..1934.02 rows=1 width=0)
-> Nested Loop Left Join (cost=1.18..1926.66 rows=2943 width=0)
Join Filter: ("outer".callsign ~ ("inner".pattern)::text)
-> Seq Scan on "Extra" (cost=0.00..866.00 rows=2943 width=10)
Filter: (geo_region = 4)
-> Materialize (cost=1.18..1.34 rows=16 width=7)
-> Seq Scan on "GeoRestrict" (cost=0.00..1.16 rows=16
width=7)
Note that this used to be just a LEFT JOIN (which also worked), but
today I wanted to include rows from "GeoRestrict" that had nulls for the
left-hand-side of the query, so I changed the LEFT JOIN to a FULL JOIN
(that worked), and then attempted to add a condition to restrict which
rows were included from "GeoRestrict", and that gave the error.
-- Dean
---------------------------(end of broadcast)---------------------------
TIP 1: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to [EMAIL PROTECTED] so that your
message can get through to the mailing list cleanly