Sql-Server数据库设计 [英] Sql-Server DataBase Design

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

问题描述

大家好,



我需要你对我的第一个数据库设计的看法





我想设计一个通用数据库,其中所有字段都将由数据库值控制。



例如:=我需要插入

医院详细信息:医院名称,地址,zipCode等。
保险详情:公司名称,电话号码等





因为我正在拿一张桌子名字提供者会有点像这样:

  ID   ProviderName   FieldName  
1医院名称
2医院zipCode
3保险公司名称
4保险电话号码





第二张表将获取与上表相关的价值:

 ProviderId Value 
1 Hospital1
2 111111
1 Hospital2
2 222222





并且在Pivot的帮助下它会显示一些这样的东西

 Hospital1 111111 
Hospital2 222222





我写的?或者有更好的方法或者如果有任何相关的教程将会很感激







谢谢和问候,

解决方案

看看这本书的一些想法...早期版本有很好的评论

数据库+设计+为+仅仅+凡人 [ ^

Hello all,

I Need Your opinion on my first DataBase Design


I want to design a Generic database in which all fields will be controlled by database values.

for example:= i need to insert

hospital detail  :     Hospital Name,Adress,zipCode etc.
Insurance Detail:     Company name, PhoneNo        etc.
.
.
.


for that i am taking one table Name Provider which will Be Some Thing Like This:

ID  ProviderName    FieldName 
1      Hospital              Name
2      Hospital               zipCode
3      Insurance              Companyname
4      Insurance              PhoneNo



Second Table Will Take the valued Related To Upper Table:

ProviderId               Value
1                        Hospital1
2                        111111
1                        Hospital2
2                        222222



and with the help of Pivot it will display some thing like this

Hospital1            111111
Hospital2            222222



Am i Write ?? or there is any better approach Or if there is any Tutorial related to this that will be appreciate



Thanks and Regards,

解决方案

Have a look at this book for some ideas ... earlier editions had good reviews
database+design+for+mere+mortals[^]


这篇关于Sql-Server数据库设计的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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