Re: [SQL] multi column foreign key for implicitly unique columns

2004-08-19 Thread Josh Berkus
Jan, > Because the value in b.y is redundant. b.x->a.x->a.y is exactly the same > value and he even wants to ensure this with the constraint. And in the absence of that constraint, what ensures that b.y = a.y, exactly? -- Josh Berkus Aglio Database Solutions San Francisco ---

Re: [SQL] multi column foreign key for implicitly unique columns

2004-08-19 Thread Oliver Elphick
On Thu, 2004-08-19 at 17:21, Josh Berkus wrote: > Jan, > > > Because the value in b.y is redundant. b.x->a.x->a.y is exactly the same > > value and he even wants to ensure this with the constraint. > > And in the absence of that constraint, what ensures that b.y = a.y, exactly? In the absence

Re: [SQL] multi column foreign key for implicitly unique columns

2004-08-19 Thread Jan Wieck
On 8/19/2004 12:52 PM, Oliver Elphick wrote: On Thu, 2004-08-19 at 17:21, Josh Berkus wrote: Jan, > Because the value in b.y is redundant. b.x->a.x->a.y is exactly the same > value and he even wants to ensure this with the constraint. And in the absence of that constraint, what ensures that b.y =

Re: [SQL] SQL Challenge: Arbitrary Cross-tab

2004-08-19 Thread Greg Sabino Mullane
-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

Re: [SQL] SQL Challenge: Arbitrary Cross-tab

2004-08-19 Thread Tom Lane
"Greg Sabino Mullane" <[EMAIL PROTECTED]> writes: >> 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 t