|
|
|
|
|
by mrkaye97
9 days ago
|
|
Thanks! I should have clarified - we haven't been using this pattern for selective joins. Strongly agreed that pulling down extra data into memory and then doing the filtering doesn't make much sense. We've found it useful in the case where it's hard to write a query where the planner _does_ make good decisions because of the complexity of the join conditions (e.g. joins using cases, a boolean "or", or something similar). Also, to re-emphasize: we do this rarely, but it's been helpful the times we've done it |
|
* Materialised views (especially if the computation/joins are particularly nasty).
* Left outer joins are a good alternative to 'joins using case' and more likely to use the index.