Closed isovector closed 2 years ago
for what it's worth, the following sql succeeds:
SELECT
CAST("doc_id0_7" AS int8) as "d_docId",
CAST("uri1_7" AS text) as "d_uri"
FROM (SELECT
*
FROM (SELECT
"id" as "id0_1",
CAST("src" AS int8) as "src1_1",
CAST("dst" AS int8) as "dst2_1"
FROM "public"."edges" as "T1") as "T1",
LATERAL
(SELECT
"doc_id" as "doc_id0_3",
"uri" as "uri1_3"
FROM "public"."discovery" as "T1") as "T2",
LATERAL
(SELECT
"doc_id" as "doc_id0_7",
"uri" as "uri1_7"
FROM "public"."discovery" as "T1") as "T3"
WHERE (("dst2_1") = ("doc_id0_7")) AND ((("src1_1") = ("doc_id0_3")) AND (CAST(("uri1_3") LIKE (CAST(E'%marginalrevolution.com%' AS text)) AS bool)))) as "T1"
with explicit type casts for src1_1
and dst2_1
.
What is the type of the src
column of "public"."edges"
in your schema? The error message operator does not exist: text = bigint
makes me think that it's a text
. If so then your definition of e_src :: Column f DocId
seems to be at odds with the schema.
Right you are; sorry about that!
Thanks for helping there, @tomjaguarpaw!
Given the following definitions:
the following
Query (Discovery Expr)
:produces the following sql:
which fails to run: