On Sunday, 11 January, 2015 11:22, Rich Shepard said:
> Items to be raffled can be donated or purchased. The Donations and
>Purchases tables each have the item ID as their PK.
> The Raffles table should have the PK as either the Donations or the
>Purchases item ID. How do I write the DDL cr
On Sun, 11 Jan 2015, Simon Slavin wrote:
You can't do the latter. Foreign keys can reference only one table. You
could create yet another table, which just supplies primary keys, but it
would seem that this would just duplicate a function of your 'items'
table.
Simon,
That's what I though
On Sun, Jan 11, 2015 at 12:21 PM, Rich Shepard
wrote:
> Items to be raffled can be donated or purchased. The Donations and
> Purchases tables each have the item ID as their PK.
>
> The Raffles table should have the PK as either the Donations or the
> Purchases item ID. How do I write the DDL
On 11 Jan 2015, at 6:21pm, Rich Shepard wrote:
> I've only had a
> foreign key reference one specific table, not either of two tables
You can't do the latter. Foreign keys can reference only one table. You could
create yet another table, which just supplies primary keys, but it would seem
t
Items to be raffled can be donated or purchased. The Donations and
Purchases tables each have the item ID as their PK.
The Raffles table should have the PK as either the Donations or the
Purchases item ID. How do I write the DDL creating the Raffles table so that
the PK is either a donated or
5 matches
Mail list logo