469,917 Members | 1,746 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,917 developers. It's quick & easy.

Perfomance Enhancement through proper database designing

Dear Reader

I am trying to design a database. How can I make best Judgement that Indexing (which I am trying to fix during Diagram Desingning process)is ok.

I am able to identify the best candidate for the indexing.

Below is the details I want to understand:

Area
ZIP
City
County
District
State/Province
Country

Now I want the data retrival optimization through Index. (you can suggest another idea, also)

Entities Area,...., Country have independent tables.
Example:

Area_Table
AreaID (PK)
Area
They have relationship- one to many- if you go from Country to Area.

There is one more table:

Location_Table (PK)
LocationID
AreaID
ZIPID
CityID
CountyID
DistrictID
State/ProvinceID
CountryID

(Location_ID is further related to the Address of the contact.)

GUI has a single form to enter these details.On a save command details in all the tables -Area to Country- (individually) being inserted.
& simultaniously Location_Table is also being inserted with the details.

Following is the situation of being queried these tables:

(1) GUI user can select an Area than the related details of ZIP .., ..., ...upto Country etc. should be loaded automatically (id it is previously stored by the user entry in the database.)
(2) Contacts have to be retrived on the basis of Area, ZIP, .....County. (Necessary Groupings are required )

Example:
If Contacts are queried Country Wise then the Display should be
Country1
State1
District1
County1
City1
ZIP1
Area1
Area2
ZIP2
City2

County2
District2
Country2

Please Guide.

SuryaPrakash

*****************************************
* This message was posted via http://www.sqlmonster.com
*
* Report spam or abuse by clicking the following URL:
* http://www.sqlmonster.com/Uwe/Abuse....255a1765491f15
*****************************************
Jul 20 '05 #1
5 1289
SuryaPrakash Patel via SQLMonster.com (fo***@SQLMonster.com) writes:
I am trying to design a database. How can I make best Judgement that
Indexing (which I am trying to fix during Diagram Desingning process)is
ok.


I was not really able to understand exactly what the queries would look
like. While a trained database designer certainly puts indexes already
in the early design stage, it's better to focus to get the data model
right to support the functional requirements first. Once we have the
queries and the tables, it may be eaesier to say what would be the
best indexes.

--
Erland Sommarskog, SQL Server MVP, es****@sommarskog.se

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinf...2000/books.asp
Jul 20 '05 #2
On Tue, 09 Nov 2004 04:32:02 GMT, SuryaPrakash Patel via SQLMonster.com
wrote:
Dear Reader

I am trying to design a database.

(snip)

Hi SuryaPrakash,

Further to Erlands's comments: you should also not think about GUI or
report formats when designing a database. Database design should be driven
by the structure of the data only.

Only when you have a properly normalized database that will store all data
the application needs and that will reject all modifications that would
hurt data integrity comes the time to think about the user interface (both
for in- and output screens and for reports) and about adding extra indexes
for performance enhancement.

Best, Hugo
--

(Remove _NO_ and _SPAM_ to get my e-mail address)
Jul 20 '05 #3
Dear Erland & Hugo

Thanks

I got your suggestions.

I have specific needs to get the certain ways of output. So it is obvious that I incorporate the needs while doing the database design.

But nowonwards I will try to stick the database structure, only. And leave the GUI part and Indexing part for later stages of development.

Point to be noted is that I will not have any chance to deploy any index after the software has been installed at user's end. Any comments.

Thanks again

SuryaPrakash

*****************************************
* A copy of the whole thread can be found at:
* http://www.sqlmonster.com/Uwe/Forum....ql-server/5093
*
* Report spam or abuse by clicking the following URL:
* http://www.sqlmonster.com/Uwe/Abuse....931f7dbd3d74e1
*****************************************
Jul 20 '05 #4
On Wed, 10 Nov 2004 00:59:23 GMT, SuryaPrakash Patel via SQLMonster.com
wrote:
Point to be noted is that I will not have any chance to deploy any index after the software has been installed at user's end. Any comments.


Hi SuryaPrakash,

That's a logical and quite common scenario. That's why you should only
install the software when it's completely finished. I'd recommend to build
the software first, then test and debug until it works as desired, then
start doing performance test and tweaking things (adding indexes,
rewriting queries, etc) until the speed is as desired. Then do a final
test to check that performance tweaking didn't break functionality.

Installing at the user's end should be postponed until all these stages
are done and the product is completely finished.

Best, Hugo
--

(Remove _NO_ and _SPAM_ to get my e-mail address)
Jul 20 '05 #5
SuryaPrakash Patel via SQLMonster.com (fo***@SQLMonster.com) writes:
Point to be noted is that I will not have any chance to deploy any index
after the software has been installed at user's end. Any comments.


So you need to test carefully with real-world data before you ship.
--
Erland Sommarskog, SQL Server MVP, es****@sommarskog.se

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinf...2000/books.asp
Jul 20 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Franco Lombardo | last post: by
4 posts views Thread by Dalan | last post: by
104 posts views Thread by cody | last post: by
2 posts views Thread by James T. | last post: by
19 posts views Thread by Krishanu Debnath | last post: by
4 posts views Thread by =?Utf-8?B?VmVlcmFiaGFkcmFpYWggTCBN?= | last post: by
8 posts views Thread by =?Utf-8?B?QmVu?= | last post: by
1 post views Thread by Waqarahmed | last post: by
reply views Thread by Salome Sato | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.