Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.databases.ms-sqlserver > #1692
| Path | csiph.com!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!newsfeed.fsmpi.rwth-aachen.de!eternal-september.org!feeder.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail |
|---|---|
| From | Gene Wirchenko <genew@telus.net> |
| Newsgroups | comp.databases.ms-sqlserver |
| Subject | Re: Is it really any point to have a relation in this example |
| Date | Thu, 20 Feb 2014 09:49:07 -0800 |
| Organization | A noiseless patient Spider |
| Lines | 31 |
| Message-ID | <pofcg995jds15hnfds3fu341d2jtnlq0i2@4ax.com> (permalink) |
| References | <le2d1u$ea1$1@dont-email.me> |
| Mime-Version | 1.0 |
| Content-Type | text/plain; charset=us-ascii |
| Content-Transfer-Encoding | 7bit |
| Injection-Info | mx05.eternal-september.org; posting-host="c80a266125e79e096da5d476a27ae8e5"; logging-data="2255"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+b0PhjYZJ7WMoBXUOknZ22vC8XUcj64nA=" |
| X-Newsreader | Forte Agent 4.2/32.1118 |
| Cancel-Lock | sha1:G1vijEpkyAjEunI5TQHVid0OQ2w= |
| Xref | csiph.com comp.databases.ms-sqlserver:1692 |
Show key headers only | View raw
On Wed, 19 Feb 2014 14:53:51 +0100, "Tony Johansson"
<johansson.andersson@telia.com> wrote:
>Assume that we have many products for example flowers but we have only one
>warehounse where we plant and store
>these flowers.
This can be read as one warehouse in total and one for each type.
If the former, you might not need a warehouse column.
>So one Inventory has many flowers but one flower can only exist in one
>warehouse.
>
>In this example is it any point to create a separate table for warehouse.
>Is it just as good to store information such as current quantity for each
>flower that exist in the product table.
>
>I find it funny to have a table warehouse with just an Id without any more
>fields.
1) It makes the validation not be hard-coded. If you add another
warehouse, you can just insert to the table.
2) You can add warehouse columns, and I would be unlikely to create
a table with just a PK. I would, at least, have a description. As
time goes on, you might decide that there are other things about the
warehouse that you wish to track.
Sincerely,
Gene Wirchenko
Back to comp.databases.ms-sqlserver | Previous | Next — Previous in thread | Find similar
Is it really any point to have a relation in this example "Tony Johansson" <johansson.andersson@telia.com> - 2014-02-19 14:53 +0100
Re: Is it really any point to have a relation in this example Erland Sommarskog <esquel@sommarskog.se> - 2014-02-19 21:13 +0100
Re: Is it really any point to have a relation in this example rja.carnegie@gmail.com - 2014-02-19 13:43 -0800
Re: Is it really any point to have a relation in this example Gene Wirchenko <genew@telus.net> - 2014-02-20 09:49 -0800
csiph-web