Re: [HACKERS] Equivalence Rules
There are 2 kinds of rules in this document: for joins and for set operations. As for joins, I think they are all about *inner* joins. Postgres (IMO) "implements" them by not doing anything special if query only contains inner joins. On the other hand, attention has to be paid if there's at least one *outer* join in the query. Identities summarized in 'Valid OUTER JOIN Optimizations' section of optimizer/README come into play then. I think make_outerjoininfo() is the code to recognize these relationships in the original query, and join_is_legal() then to check if new joins (those not present in the original query) do not change the semantics. (As for set operations, someone else needs to explain.) // Antonin Houska (Tony) On 03/02/2014 09:02 AM, Ali Piroozi wrote: > Hi > > My question is: > Does PostgreSQL implements equivalence rules(from those are listed in > email's attachment)? > Which function or which part of source code(in PostgreSQL ) implements > the equivalence rules? > I think, this should be implemented in query optimization part of > PostgreSQL, but which rule > and where, I don't know? > I want to use that(function or part of source code), to produce the > equivalence Relational Algebras (based on equivalence rules in > attachment) for a given SQL query(Relational Algebra). > > Thanks > > > > -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
[HACKERS] Equivalence Rules
Hi My question is: Does PostgreSQL implements equivalence rules(from those are listed in email's attachment)? Which function or which part of source code(in PostgreSQL ) implements the equivalence rules? I think, this should be implemented in query optimization part of PostgreSQL, but which rule and where, I don't know? I want to use that(function or part of source code), to produce the equivalence Relational Algebras (based on equivalence rules in attachment) for a given SQL query(Relational Algebra). Thanks EquivalenceRules.pdf Description: Adobe PDF document -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
Re: [HACKERS] Equivalence Rules
"where" means, which function or which part of source code. I want to use that(function or part of source code), to produce the equivalence (based on equivalence rules in attachment) Relational Algebra for a given SQL query(Relational Algebra).
Re: [HACKERS] Equivalence Rules
Ali Piroozi wrote > Hi > Which equivalence rule from those are listed in > email's attachment are implemented in postgresql? > where are them? What do you mean by "where"? The various JOINS and UNION/INTERSECT/DIFFERENCE are all defined capabilities. SQL is not purely relational in nature so some of the mathematical rules may not be exactly implemented as theory would dictate but largely they are present. I would suggesting providing more context as to why you are asking this as people are more likely to provide help at this level of technical depth if they know why; and can frame their answers more appropriately. David J. -- View this message in context: http://postgresql.1045698.n5.nabble.com/Equivalence-Rules-tp5794035p5794069.html Sent from the PostgreSQL - hackers mailing list archive at Nabble.com. -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
[HACKERS] Equivalence Rules
Hi Which equivalence rule from those are listed in email's attachment are implemented in postgresql? where are them? Thanks equivalenceRules.pdf Description: Adobe PDF document -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers