后续设计问题 [英] Followup to design question

查看:62
本文介绍了后续设计问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

好。我完成了我的作业,研究了公司模型,研究过
Access,并写了我的第一个骨架关系图

我相信是NF3。这是一个链接:

http://johnharris34.googlepages.com /数据库


我基本上想知道它是如何设置

的问题,因为它看起来似乎与其他图表相比有点奇怪我已经看了,但是我不确定如何准确地表示我的数据模型

。说明:


(StockNumber是一个内部(由办公室经理)生成的数字

,它始终是唯一的。)


[Products]代表所有extras我们出售,如延长

保修,皮革保护,搭便车等(我们销售的产品总数约为10美元。)我们通常会出售带附加功能的汽车<作为销售的一部分投入了
,有时没有额外的东西

购买。有时我们自己出售额外的东西,没有任何

汽车销售(在那些情况下[ProductSales]。[AutoStockNumber]将是

NULL。)有*实际上* a

汽车销售和销售之间的一对一关系,因为我们从不销售多辆汽车作为一个销售的一部分

;然而,正如你在图表中看到的那样,我已经将它设置为

一对多。


我感谢我能得到的任何反馈这个模型。

解决方案

JohnH写道:


好​​的。我完成了我的作业,研究了公司模型,研究过
Access,并写了我的第一个骨架关系图

我相信是NF3。这是一个链接:

http://johnharris34.googlepages.com /数据库


我基本上想知道它是如何设置

的问题,因为它看起来似乎与其他图表相比有点奇怪我已经看了,但是我不确定如何准确地表示我的数据模型

。说明:


(StockNumber是一个内部(由办公室经理)生成的数字

,它始终是唯一的。)


[Products]代表所有extras我们出售,如延长

保修,皮革保护,搭便车等(我们销售的产品总数约为10美元。)我们通常会出售带附加功能的汽车<作为销售的一部分投入了
,有时没有额外的东西

购买。有时我们自己出售额外的东西,没有任何

汽车销售(在那些情况下[ProductSales]。[AutoStockNumber]将是

NULL。)有*实际上* a

汽车销售和销售之间的一对一关系,因为我们从不销售多辆汽车作为一个销售的一部分

;但是正如你在图表中看到的那样,我已经将它设置为

一对多。



一些简单的想法。


在我看来,车辆是它自己的实体。车辆存在

没有销售。


不知道我会如何处理交易信息。我想这可能是因为在单一销售中可以买到一辆以上的车辆。

。如果是这样的信息交易属于另一个表格。


您如何确定Sales

表中SaleId所指的哪个其他表?


3月6日上午11点20分,rkc< r ... @ rkcny.yabba.dabba.do.comwrote:


JohnH写道:


好​​的。我完成了我的作业,研究了公司模型,研究过
Access,并写了我的第一个骨架关系图

我相信是NF3。这是一个链接:

http ://johnharris34.googlepages.com/database


我基本上想知道它是如何设置的问题

因为与其他图表相比看起来确实有些奇怪我已经看了,但是我不知道如何再代表我的数据模型了/>
准确。说明:


(StockNumber是内部(由办公室经理)生成的数字

,它始终是唯一的。)


[Products]代表所有extras"我们出售,如延长

保修,皮革保护,搭便车等(我们销售的产品总数约为10美元。)我们通常会出售带附加功能的汽车<作为销售的一部分投入了
,有时没有额外的东西

购买。有时我们自己出售额外的东西,没有任何

汽车销售(在那些情况下[ProductSales]。[AutoStockNumber]将是

NULL。)有*实际上* a

汽车销售和销售之间的一对一关系,因为我们从不销售多辆汽车作为一个销售的一部分

;但是正如你在图表中看到的那样,我已经将它设置为

一对多。



一些简单的想法。


在我看来,车辆是它自己的实体。车辆存在

没有销售。


不知道我会如何处理交易信息。我想这可能是因为在单一销售中可以买到一辆以上的车辆。

。如果是这样的信息交易属于另一个表格。


您将如何确定Sales

表中SaleId引用的哪个其他表? - 隐藏引用的文本 -


- 显示引用的文字 -


在我看来,车辆是它的一个实体''自己的。车辆存在没有销售的



是的,这是真的,我想我可以将表格分成我们的商业模式改变的机会

。然而,目前从来没有一个b / b需要独立于销售来跟踪车辆,因为作为经纪人,我们只是促进汽车交易;我们没有这样的正式

库存。


不知道我将如何处理交易信息。我想这可能是因为在单一销售中可以买到一辆以上的车辆。

。如果是这样,信息交易属于另一个表。



我被告知从来没有出现过多次以旧换新的方式

的车辆,尽管我本来打算把它分开来

(并且应该在放图之前),因为没有

点画我自己到角落里。


您如何确定Sales

表中SaleId所指的哪个其他表?



我会说这是一个很好的问题,因为我不知道如何回答:D

我猜你的意思是我怎么知道Sale的用途?

是不是可以加入三个表(Sales,AutoSales,

ProductSales)来检索任何信息我需要?我还没有开始对桌子进行查询,而且我的有限的b
经验并没有让我眼前一亮。或许它是一个好主意在销售中放置一个布尔字段来表示

车辆是否作为销售的一部分被购买?您认为

是潜在的问题?


>目前,从来没有


>需要独立于销售跟踪车辆,因为作为经纪人,我们只促进汽车交易;我们没有这样的正式库存。



我想我真的不知道你在建模什么。

经纪人到底做了什么?


Okay. I''ve done my homework, researched the company model, researched
Access, and have written up my first skeletal relationship diagram
that I believe is NF3. Here is a link:

http://johnharris34.googlepages.com/database

I''m essentially wondering if there''s a problem with how it''s set up
because it does seem slightly strange compared to other diagrams I''ve
looked at, but I''m not sure how to represent my data model any more
accurately. Explanation:

(StockNumber is an internally (by the office manager) generated number
that is always unique.)

[Products] represents all the "extras" we sell, like extended
warranties, leather protection, hitch, etc. (There are about 10
products total that we sell.) We usually sell a car with extras
thrown in as part of the sale, sometimes there are no extras
purchased. And sometimes we sell extras by themselves, without any
car sale (in those instances [ProductSales].[AutoStockNumber] will be
NULL.) There is *actually* a one-to-one relationship between
AutoSales and Sales, because we never sell more than one car as part
of one sale; however as you can see in the diagram I''ve set it up as
one-to-many.

I appreciate any feedback I can get on this mock-up.

解决方案

JohnH wrote:

Okay. I''ve done my homework, researched the company model, researched
Access, and have written up my first skeletal relationship diagram
that I believe is NF3. Here is a link:

http://johnharris34.googlepages.com/database

I''m essentially wondering if there''s a problem with how it''s set up
because it does seem slightly strange compared to other diagrams I''ve
looked at, but I''m not sure how to represent my data model any more
accurately. Explanation:

(StockNumber is an internally (by the office manager) generated number
that is always unique.)

[Products] represents all the "extras" we sell, like extended
warranties, leather protection, hitch, etc. (There are about 10
products total that we sell.) We usually sell a car with extras
thrown in as part of the sale, sometimes there are no extras
purchased. And sometimes we sell extras by themselves, without any
car sale (in those instances [ProductSales].[AutoStockNumber] will be
NULL.) There is *actually* a one-to-one relationship between
AutoSales and Sales, because we never sell more than one car as part
of one sale; however as you can see in the diagram I''ve set it up as
one-to-many.

A few quick thoughts.

Seems to me that Vehicle is an entity of it''s own. Vehicles exist
without a sale.

Not sure what I would do with the trade in info. I suppose it is
possible that more than one vehicle could be taken in trade on a
single sale. If so trade in info belongs in another table.

How will you determine which other table the SaleId in the Sales
table refers to?


On Mar 6, 11:20 am, rkc <r...@rkcny.yabba.dabba.do.comwrote:

JohnH wrote:

Okay. I''ve done my homework, researched the company model, researched
Access, and have written up my first skeletal relationship diagram
that I believe is NF3. Here is a link:

http://johnharris34.googlepages.com/database

I''m essentially wondering if there''s a problem with how it''s set up
because it does seem slightly strange compared to other diagrams I''ve
looked at, but I''m not sure how to represent my data model any more
accurately. Explanation:

(StockNumber is an internally (by the office manager) generated number
that is always unique.)

[Products] represents all the "extras" we sell, like extended
warranties, leather protection, hitch, etc. (There are about 10
products total that we sell.) We usually sell a car with extras
thrown in as part of the sale, sometimes there are no extras
purchased. And sometimes we sell extras by themselves, without any
car sale (in those instances [ProductSales].[AutoStockNumber] will be
NULL.) There is *actually* a one-to-one relationship between
AutoSales and Sales, because we never sell more than one car as part
of one sale; however as you can see in the diagram I''ve set it up as
one-to-many.


A few quick thoughts.

Seems to me that Vehicle is an entity of it''s own. Vehicles exist
without a sale.

Not sure what I would do with the trade in info. I suppose it is
possible that more than one vehicle could be taken in trade on a
single sale. If so trade in info belongs in another table.

How will you determine which other table the SaleId in the Sales
table refers to?- Hide quoted text -

- Show quoted text -

Seems to me that Vehicle is an entity of it''s own. Vehicles exist
without a sale.

Yes, that is true, and I suppose I could split the table on the chance
that our business model changes. Currently, however, there is never a
need to track vehicles independently of sales because as a brokerage,
we only facilitate transactions of cars; we don''t have a formal
inventory as such.

Not sure what I would do with the trade in info. I suppose it is
possible that more than one vehicle could be taken in trade on a
single sale. If so trade in info belongs in another table.

I''ve been told there is never a situation where more than one trade-in
is taken in on a vehicle, although I''ve planned to split it out anyway
(and should have before putting that diagram up), since there''s no
point painting myself into a corner.

How will you determine which other table the SaleId in the Sales
table refers to?

I''d say that''s a good question since I''m not sure how to answer it :D
I guess you mean how will I know what the Sale was for?
Isn''t it possible to join the three tables (Sales, AutoSales,
ProductSales) to retrieve whatever information I need? I haven''t
started writing queries against the tables yet, and my limited
experience doesn''t throw much light ahead of me to see by. Perhaps it
would be a good idea to put a boolean field in Sales to indicate
whether a vehicle was purchashed as part of the Sale? What do you see
as the potential problem?


>Currently, however, there is never a

>need to track vehicles independently of sales because as a brokerage,
we only facilitate transactions of cars; we don''t have a formal
inventory as such.

I guess I don''t really know what you''re modeling then.
What exactly does a brokerage do?


这篇关于后续设计问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆