X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id 322C09DCA52 for ; Sat, 18 Mar 2006 11:04:00 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 49833-04 for ; Sat, 18 Mar 2006 11:04:03 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from hotmail.com (bay107-dav17.bay107.hotmail.com [64.4.51.89]) by postgresql.org (Postfix) with ESMTP id 48EA39DC83A for ; Sat, 18 Mar 2006 11:03:57 -0400 (AST) Received: from mail pickup service by hotmail.com with Microsoft SMTPSVC; Sat, 18 Mar 2006 07:04:01 -0800 Message-ID: Received: from 84.193.85.191 by BAY107-DAV17.phx.gbl with DAV; Sat, 18 Mar 2006 15:04:01 +0000 X-Originating-IP: [84.193.85.191] X-Originating-Email: [nbforyou@hotmail.com] X-Sender: nbforyou@hotmail.com From: "NbForYou" To: Subject: database model tshirt sizes Date: Sat, 18 Mar 2006 16:03:59 +0100 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_001B_01C64AA5.9182DE50" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.2180 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180 X-OriginalArrivalTime: 18 Mar 2006 15:04:01.0941 (UTC) FILETIME=[31059C50:01C64A9D] X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=1.611 required=5 tests=[AWL=-0.309, DNS_FROM_RFC_ABUSE=0.479, DNS_FROM_RFC_POST=1.44, HTML_MESSAGE=0.001, MSGID_FROM_MTA_HEADER=0] X-Spam-Score: 1.611 X-Spam-Level: * X-Archive-Number: 200603/306 X-Sequence-Number: 17743 This is a multi-part message in MIME format. ------=_NextPart_000_001B_01C64AA5.9182DE50 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hello, Does anybody know how to build a database model to include sizes for = rings, tshirts, etc? the current database is built like: table product =3D=3D=3D=3D=3D=3D=3D=3D=3D productid int8 PK productname charvar(255) quantity int4 what i want now is that WHEN (not all products have multiple sizes) = there are multiple sizes available. The sizes are stored into the = database. I was wondering to include a extra table: table sizes: =3D=3D=3D=3D=3D=3D=3D=3D productid int8 FK size varchar(100) but then i have a quantity problem. Because now not all size quantities = can be stored into this table, because it allready exist in my product = table. How do professionals do it? How do they make their model to include = sizes if any available? ------=_NextPart_000_001B_01C64AA5.9182DE50 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
Hello,
 
Does anybody know how to build a = database model to=20 include sizes for rings, tshirts, etc?
 
 
the current database is built = like:
 
table product
=3D=3D=3D=3D=3D=3D=3D=3D=3D
 
productid int8 PK
productname charvar(255)
quantity int4
 
 
what i want now is that WHEN (not all = products have=20 multiple sizes) there are multiple sizes available. The sizes are stored = into=20 the database. I was wondering to include a extra table:
 
table sizes:
=3D=3D=3D=3D=3D=3D=3D=3D
productid int8 FK
size varchar(100)
 
 
but then i have a quantity problem. = Because now not=20 all size quantities can be stored into this table, because it allready = exist in=20 my product table.
 
How do professionals do it? How do they = make their=20 model to include sizes if any available?
------=_NextPart_000_001B_01C64AA5.9182DE50--