Re: [GENERAL] unable to call a function

2013-07-07 Thread giozh
ok, now it works with varchar args. thanks -- View this message in context: http://postgresql.1045698.n5.nabble.com/unable-to-call-a-function-tp5762590p5762891.html Sent from the PostgreSQL - general mailing list archive at Nabble.com. -- Sent via pgsql-general mailing list (pgsql-general@p

[GENERAL] Computing count of intersection of two queries (Relational Algebra --> SQL)

2013-07-07 Thread Robert James
In relational algebra, I have relation R and relation S, and want to find the cardinality of R, of S, and of R-intersect-S. I know the SQL for R and S. What's the best way to compute the cardinality of each relation (query) and of their intersection? -- Sent via pgsql-general mailing list (pgs

[GENERAL] Re: Computing count of intersection of two queries (Relational Algebra --> SQL)

2013-07-07 Thread David Johnston
Robert James wrote > In relational algebra, I have relation R and relation S, and want to > find the cardinality of R, of S, and of R-intersect-S. > > I know the SQL for R and S. What's the best way to compute the > cardinality of each relation (query) and of their intersection? WITH r (id) AS (