Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 Database Design and Application Architecture
 Denormalization?

Author  Topic 

Miguel05
Starting Member

2 Posts

Posted - 2008-12-02 : 14:59:10
Hi guys,

The following tables are related to my question:

ITEM:
ItemID
Some fields..
CityID

CITY:
CityID
CityDescription
ProvinceID

PROVINCE:
ProvinceID
ProvinceDescription
CountryID

COUNTRY:
CountryID
CountryDescription

The database will be used as the new database for an ebay-like website which currently has about 300.000 visitors a day, so good performance is required, but I also would like to have a good database model.

Visitors of the website can search for an item by City, Province and Country. Is it better to copy CityID, ProvinceID, and CountryID to the item table to increase performance?

Thanks

blindman
Master Smack Fu Yak Hacker

2365 Posts

Posted - 2008-12-02 : 15:02:51
Try creating indexed views if you want to improve SELECT performance.

________________________________________________
If it is not practically useful, then it is practically useless.
________________________________________________
Go to Top of Page

spirit1
Cybernetic Yak Master

11752 Posts

Posted - 2008-12-02 : 15:04:00
i have seen optimizations like this, but you'll have to weigh the cost of updates.
how much will this data change?
i'd suggest to create an indexed view with the searchable data. it should provide enough performance.

___________________________________________________________________________
Causing trouble since 1980
Blog: http://weblogs.sqlteam.com/mladenp
Speed up SSMS development: www.ssmstoolspack.com <- version 1.1 out!
Go to Top of Page

Miguel05
Starting Member

2 Posts

Posted - 2008-12-02 : 15:18:52
Once an item has been created, it's not very likely to change location.
Thanks for the info, I'll look into the indexed views.
Go to Top of Page
   

- Advertisement -