Re: [GENERAL] How to intelligently work with views that depend on other views

2015-08-09 Thread Berend Tober
Melvin Davidson wrote: The best solution, IMHO, is don't create views that depend on other views. ... Much better to just make each view a stand alone. Seconding Mr. Davidson's advice. But, given that you are in the situation, here is a workable alternative: Matthew Wilson On Thu, Aug 6,

[GENERAL] How to intelligently work with views that depend on other views

2015-08-06 Thread W. Matthew Wilson
I have a bunch of views, and some views use data from other views. For example, view A might get used by view B and view B gets used by view C. Several times now, as I got further into the project, I've changed how I make some views and I've had to redefine not just that view, but all the ones

Re: [GENERAL] How to intelligently work with views that depend on other views

2015-08-06 Thread Adrian Klaver
On 08/06/2015 01:44 PM, W. Matthew Wilson wrote: I have a bunch of views, and some views use data from other views. For example, view A might get used by view B and view B gets used by view C. Several times now, as I got further into the project, I've changed how I make some views and I've had

Re: [GENERAL] How to intelligently work with views that depend on other views

2015-08-06 Thread Melvin Davidson
The best solution, IMHO, is don't create views that depend on other views. Although, it makes it easier in some cases, you pay the price in maintenance, as you have already found out. In addition, there is also the security problem that comes into play. EG: a user is allowed access to view c, but

Re: [GENERAL] How to intelligently work with views that depend on other views

2015-08-06 Thread Melvin Davidson
Correction, as Mr. Tober suggested. On Thu, Aug 6, 2015 at 8:34 PM, Melvin Davidson melvin6...@gmail.com wrote: As Mr. Wilson suggested, you can use pg_dump to extract the views, but I also suggest downloading and installing pg_extractor, which uses pg_dump but allows more options to dump

Re: [GENERAL] How to intelligently work with views that depend on other views

2015-08-06 Thread Melvin Davidson
As Mr. Wilson suggested, you can use pg_dump to extract the views, but I also suggest downloading and installing pg_extractor, which uses pg_dump but allows more options to dump just the objects you need. IE: views, functions, etc. Here's the url to download.