From: | Andrew Sullivan <andrew(at)libertyrms(dot)info> |
---|---|
To: | PostgreSQL General List <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: Questions about my strategy |
Date: | 2002-07-30 14:34:40 |
Message-ID: | 20020730103440.C5295@mail.libertyrms.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Tue, Jul 30, 2002 at 01:58:33PM +1200, Rob Brown-Bayliss wrote:
> The business is shoe retail, so he buys a shoe, say it's called "Trek"
> made by "Joes Shoe makers". When He buys 400 of these, they might be
> 200 white, 100 black, 100 red, but also spread accross 10 different
> sizes.
>
> On other systems he has had to have aproduct code for each possible
> combo, one for wihte size 35, one for white size 35.5 etc.
>
> Then he cant get a count of how many "treks" he has in stock. I
> fuggured this way I can give a simple "389 total treks in stock" answer,
> or a "137 white treks" or a "24 white size 35 treks".
Why not three codes: model, colour, and size? Then you can query all
by model, and limit by size, colour, or both.
I think your strategy will work, but it has the potential to degrade
seriously over time, or else to require some sort of regular
maintenance. Nothing wrong with that, of course, just a potential
pitfall.
A
--
----
Andrew Sullivan 87 Mowat Avenue
Liberty RMS Toronto, Ontario Canada
<andrew(at)libertyrms(dot)info> M6K 3E3
+1 416 646 3304 x110
From | Date | Subject | |
---|---|---|---|
Next Message | Andrew Sullivan | 2002-07-30 14:36:17 | Re: Importing data |
Previous Message | Robert Treat | 2002-07-30 14:22:58 | Re: [GENERAL] log sql? |