Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Table Design Question

Status
Not open for further replies.

itflash

Programmer
Jul 18, 2001
535
GB


Hi all

I have an application that allows users to work through a number of stages of a contract. The form will have tabs, which the user will work through one at a time. They can save and continue later.

My question is regarding the table design (SQL Server 2000).

Option 1
Do I have a table which contains fields for each stage, therefore all stages contained in one row?

Option 2
Or do I have a table with common fields, so one row per stage and have a stage field to identify the stage?

To me, option 1 is easier but option 2 is more "E-R" design.


Any help or comments are appreciated.


Many Thanks
ITflash



 
What happens if you want to change the process - add more stages for instance.
In option 1 you would have to changet he database structure.
For option 2 things are more flexible - you could even give users an admin app to change the workflow or have different types of contract routes.

======================================
Cursors are useful if you don't know sql.
DTS can be used in a similar way.
Beer is not cold and it isn't fizzy.
 


Thanks for the reply.

Thats the lines I was thinking along for future developments.

The only thing I would like to ask, what it the best way of ordering the stages (for example, if me or the user adds a stage, how can I create a numbering sequence that will allow inserts?) Should I number the old style way of 10, 20, 30, therefore allowing 12, when required?

Many Thanks.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top