Re: SQL Challenge: Arbitrary Cross-tab - Mailing list pgsql-sql

From Greg Sabino Mullane
Subject Re: SQL Challenge: Arbitrary Cross-tab
Date
Msg-id a1aa78544af9cfda7c505876591e95dc@biglumber.com
Whole thread Raw
In response to Re: SQL Challenge: Arbitrary Cross-tab  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: SQL Challenge: Arbitrary Cross-tab
List pgsql-sql
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
> Nope; Gaetano's right, you cannot assume that.  It's entirely possible
> for the planner to choose different plans depending on the OFFSET.
> (Maybe not very likely, with such small offsets, but could happen.)
Interesting. I realized that there was a finite chance of different
plans being chosen, but it seemed neigh-impossible since there is
no WHERE clause and the offsets only vary from 0-7. What sort of
different plans would it choose, out of curiosity?
Seq-scan vs. index-scan? Are there any particular cases where the
same plan is guaranteed to be used?
- --
Greg Sabino Mullane greg@turnstep.com
PGP Key: 0x14964AC8 200408192216
-----BEGIN PGP SIGNATURE-----
iD8DBQFBJV9xvJuQZxSWSsgRAp74AJ96mtrKC1J53y0TPqTPdq2Xost0fACg4DnJ
7P+dgpHWBazGNE9+SR7uxLY=
=MZuM
-----END PGP SIGNATURE-----




pgsql-sql by date:

Previous
From: Jan Wieck
Date:
Subject: Re: multi column foreign key for implicitly unique columns
Next
From: Tom Lane
Date:
Subject: Re: SQL Challenge: Arbitrary Cross-tab