Re: Return select statement with sql case statement - Mailing list pgsql-general

From David G. Johnston
Subject Re: Return select statement with sql case statement
Date
Msg-id CAKFQuwaWMpto-UNT3mBWz3KCzRBu0gP5e--P6xKfc4Od+b5_ow@mail.gmail.com
Whole thread Raw
In response to Re: Return select statement with sql case statement  (Ron <ronljohnsonjr@gmail.com>)
List pgsql-general
On Wednesday, July 4, 2018, Ron <ronljohnsonjr@gmail.com> wrote:
Ah, didn't notice that.  Then... dynamic sql constructed by the programming language executing the query?

That, the UNION idea, or pull the common stuff into the from clause and write two left joins then coalesce whichever one provided the row.  In short, the OP cannot do what they thought they needed to do but hasn't really provided any info for others to make alternative suggestions.

David J. 

pgsql-general by date:

Previous
From: Melvin Davidson
Date:
Subject: Re: Cloning schemas
Next
From: Łukasz Jarych
Date:
Subject: Re: Cloning schemas