Re: [OT] Inventory systems (private)

From: Andy Tawse <andy(dot)t(at)newmediacollective(dot)com>
To: pgsql-sql(at)postgresql(dot)org
Subject: Re: [OT] Inventory systems (private)
Date: 2002-12-03 14:52:34
Message-ID: MGXS1ZROPNFBMJNM3ZBAD961ZUKFOKV.3decc532@laptop
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

While I'm not expert what I would do is something like this

Items table
fields: item_id item_name

Attributes table
fields: attribute_id attribute_name

Item_Attr table
fields: item_id attribute_id attribute_value

Now an item can be associated with any number of attributes.

03/12/2002 13:17:15, "Ries van Twisk" <ries(at)jongert(dot)nl> wrote:

>Hi All,
>
>is there any whitepaper, document or website that can point me to how to
>setup a inventory system?
>I'm particulary interested how other people solve the problem of a unknown
>number of attributes to a inventory item.
>
>example:
>BAL <-- Inventory Item
> - Color <- Attribute
> - Diameter <- Attribute
> - Weight <- Attribute
>
>Car <-- Inventory Item
> - Speed <- Attribute
> - Size <- Attribute
> - Weight <- Attribute
> - Color <- Attribute
>
>Computer <-- Inventory Item
> - Brand <- Attribute
> - Weight <- Attribute
> - Windows/Linux <- Attribute
>
>
>I can ofcource add any number of columns to a table but for a lot of items
>there will be a lot of NULL values and currently I don't know how many
>attrubutes one item can have (possible between 10 and 20). This can even
>change in feature opon request.
>
>Ries
>
>
>---------------------------(end of broadcast)---------------------------
>TIP 4: Don't 'kill -9' the postmaster
>

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Alphasoft 2002-12-03 15:04:39 problem with view in 7.3
Previous Message Alphasoft 2002-12-03 14:48:07 problem with view in 7.3