Click here to Skip to main content
15,895,799 members
Home / Discussions / Database
   

Database

 
GeneralRe: Nesting Limit Pin
Andy_L_J28-Apr-12 23:45
Andy_L_J28-Apr-12 23:45 
GeneralRe: Nesting Limit Pin
Mycroft Holmes29-Apr-12 2:39
professionalMycroft Holmes29-Apr-12 2:39 
QuestionRunning Balance Pin
paulaziz26-Apr-12 15:01
paulaziz26-Apr-12 15:01 
AnswerRe: Running Balance Pin
Mycroft Holmes26-Apr-12 19:01
professionalMycroft Holmes26-Apr-12 19:01 
AnswerRe: Running Balance Pin
Blue_Boy26-Apr-12 21:44
Blue_Boy26-Apr-12 21:44 
QuestionConnect to Oracle database from Log4net.config file Pin
forum.forum26-Apr-12 0:26
forum.forum26-Apr-12 0:26 
AnswerRe: Connect to Oracle database from Log4net.config file Pin
Eddy Vluggen27-Apr-12 8:08
professionalEddy Vluggen27-Apr-12 8:08 
QuestionYour thoughts on Database Model - KPI System Pin
DaveAuld25-Apr-12 5:50
professionalDaveAuld25-Apr-12 5:50 
As part of my degree I recently submitted an interim paper and one of the feedback comments from the tutor was along the lines of "consider asking the opinions of others on the database, it is not cheating as long as you properly reference your source". Fair point I thought so here I am.

In my submission I had written about the two options I had considered for the database model and why I had elected to choose the one I did. So the question arises from this, what other options are there or what would your preferred approach be?

Basically, the project is looking at migrating an existing file based process across to a web solution, and part of the system relates to the daily reporting of end of period figures and status.

At the end of each daily reporting 24 hour period, a whole bunch of items are recorded, and these are recorded for more that one site, and not every site records the same metrics, but the majority of them are all the same.

As it stands at present there are approximately 30 parameters recorded, some numerical, some textual.

The first option I considered was row per site per period, with each column representing a metric (I will just call them param, but in reality they have meaningful names).

<id><site><period-end-date><param-n><param-n+1><param-n+2>............etc.


The second option was splitting the KPIs into groups, and have table per group with one master record identifying the site and period in another table.
Master Table
<id><site><period-end-date><KPI-group-A-ID><KPI-Group-B-ID><KPI-Group-C-ID>

KPI Group A Table
<id><param-n><param-n+1><param-n+2>............etc.

KPI Group B Table
<id><param-n><param-n+1><param-n+2>............etc.

KPI Group C Table
<id><param-n><param-n+1><param-n+2>............etc.


I originally have coded the models using code first approach (I'm using EF and MVC3) using option 2, as thought it would be easier to manage and allow for easier scaling, and appears to work well.
The part I am adding in at the moment is a losses breakdown for period, so each site might have multiple entries in a loss table linked to the Master Record in a one-to-many.

So the question is, particularly to any DBA's or architects, how would you or what suggestions would you have on how best to build the database to meet the needs, allowing for potentially more kpi parameters or groups to be added in the future.

Any thoughts greatly appreciated.
Dave
Find Me On: Web|Facebook|Twitter|LinkedIn

Folding Stats: Team CodeProject


AnswerRe: Your thoughts on Database Model - KPI System Pin
Eddy Vluggen25-Apr-12 7:09
professionalEddy Vluggen25-Apr-12 7:09 
GeneralRe: Your thoughts on Database Model - KPI System Pin
DaveAuld6-May-12 1:38
professionalDaveAuld6-May-12 1:38 
AnswerRe: Your thoughts on Database Model - KPI System PinPopular
jschell25-Apr-12 8:16
jschell25-Apr-12 8:16 
GeneralRe: Your thoughts on Database Model - KPI System Pin
Jörgen Andersson26-Apr-12 1:38
professionalJörgen Andersson26-Apr-12 1:38 
GeneralRe: Your thoughts on Database Model - KPI System Pin
DaveAuld6-May-12 1:46
professionalDaveAuld6-May-12 1:46 
QuestionHow to create SQL Backup and Restore Server-based (.mdf) Database built in Visual Studio 2010? Pin
carm_ella24-Apr-12 0:20
carm_ella24-Apr-12 0:20 
AnswerRe: How to create SQL Backup and Restore Server-based (.mdf) Database built in Visual Studio 2010? Pin
kalaisw24-Apr-12 2:58
kalaisw24-Apr-12 2:58 
JokeRe: How to create SQL Backup and Restore Server-based (.mdf) Database built in Visual Studio 2010? PinPopular
Eddy Vluggen24-Apr-12 5:03
professionalEddy Vluggen24-Apr-12 5:03 
GeneralRe: How to create SQL Backup and Restore Server-based (.mdf) Database built in Visual Studio 2010? Pin
carm_ella12-May-12 23:39
carm_ella12-May-12 23:39 
AnswerRe: How to create SQL Backup and Restore Server-based (.mdf) Database built in Visual Studio 2010? Pin
Eddy Vluggen13-May-12 4:20
professionalEddy Vluggen13-May-12 4:20 
QuestionI can not drop table after upgrading to sql 2008 r2 from sql 2005 Pin
yousefshokati22-Apr-12 21:31
yousefshokati22-Apr-12 21:31 
AnswerRe: I can not drop table after upgrading to sql 2008 r2 from sql 2005 Pin
Pete O'Hanlon23-Apr-12 0:54
mvePete O'Hanlon23-Apr-12 0:54 
GeneralRe: I can not drop table after upgrading to sql 2008 r2 from sql 2005 Pin
yousefshokati23-Apr-12 1:02
yousefshokati23-Apr-12 1:02 
GeneralRe: I can not drop table after upgrading to sql 2008 r2 from sql 2005 Pin
Pete O'Hanlon23-Apr-12 1:13
mvePete O'Hanlon23-Apr-12 1:13 
QuestionSQL 2008 to SQL2005 Pin
jojoba201122-Apr-12 21:25
jojoba201122-Apr-12 21:25 
AnswerRe: SQL 2008 to SQL2005 Pin
Blue_Boy22-Apr-12 21:43
Blue_Boy22-Apr-12 21:43 
QuestionRe: SQL 2008 to SQL2005 Pin
jojoba201122-Apr-12 22:02
jojoba201122-Apr-12 22:02 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.