Re: Indexing UNIONs - Mailing list pgsql-sql

From Richard Huxton
Subject Re: Indexing UNIONs
Date
Msg-id 200207171029.17572.dev@archonet.com
Whole thread Raw
In response to Re: Indexing UNIONs  (Josh Berkus <josh@agliodbs.com>)
List pgsql-sql
On Tuesday 16 Jul 2002 11:42 pm, Josh Berkus wrote:
> OK, I guess I'll have to get into detail:
>
[detail on cases and trial-groups]
>
> Thus, I need to relate (in views and queries) each Event to the Union of
> Cases and Trial Groups.   I just can't figure out how to do so without the
> database discarding the indexes on Cases in the process and things slowing
> to a crawl.

Well, if there was some commonality between cases and trial groups you'd have
noticed it. How about two event tables, one for each type of schedulable
event and unioning those?

Of course, that's just shuffling the complexity around since you'll need a
view with the relevant rewrites and possibly some way of detecting scheduling
conflicts?

- Richard Huxton


pgsql-sql by date:

Previous
From: Karel Zak
Date:
Subject: Re: datatype matrix (was: Re: Sorry..)
Next
From: Dirk Lutzebaeck
Date:
Subject: How to find out if an index is unique?