x
login about faq Site discussion (meta-askssc)

Is it a good practice to maintain the data in a separate table from the task table?

In my application there is a module which displays info by reading from a table. This info can be edited. Once edited there is a series of actions needs to be performed. So i am maintaining a task table which will create task for each edit made. In order to execute the task, i need the data modified by the user along with the user id. My task table structure will be like this:

TaskId 
TaskType
CreatedOn
State
CompletedOn

I am planning to have TaskType attribute based on which it will read the data from the source data table on which info is stored. Now my question is, i also need to maintain the userid to know for which user i have to fetch the data from the source data table? I don want to maintain that in TaskTable then it would become a Task of particular type. Can someone suggest on good approach for this?

more ▼

asked Aug 02 '12 at 09:37 AM in Default

vinothcz gravatar image

vinothcz
10 1

(comments are locked)
10|1200 characters needed characters left

1 answer: sort voted first

You might want a TaskProcess table that is a one to many to the Task table with a foreign key on TaskID. The TaskProcess table can track the processing done on the task with a UserID , Action and Completed (boolean) as columns.

more ▼

answered Nov 19 '12 at 03:05 PM

TheSmilingDBA gravatar image

TheSmilingDBA
81 1 1 2

(comments are locked)
10|1200 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments



Facebook logo Follow Ask SSC on Facebook
Find Ask SSC on Google+
linkedin logo Find us on LinkedIn

Topics:

x1601
x107

asked: Aug 02 '12 at 09:37 AM

Seen: 291 times

Last Updated: Nov 19 '12 at 03:05 PM

Copyright © 2002-2012 Simple Talk Publishing. All Rights Reserved. If you have any queries, please contact the site administrators.
Ask SQL Server Central is a community service provided by Red Gate.