Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3878872
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T22:39:43+00:00 2026-05-19T22:39:43+00:00

I have a timesheet application in Asp.Net MVC, but the question should be general

  • 0

I have a timesheet application in Asp.Net MVC, but the question should be general database design:

I have a number of related tables, Customer, Project, Task, Employee, TimeSegment. Now, I want to be able to relate Tasks to Employees as “resources”. And for each resource I want to be able to have information about work percentage assigned to an employee for a specific task. But I can’t wrap my head around it. As far as I can see it can’t simply be a many-to-many relationship between Task and Employee, because where would I put the percentage field then? If I put it on the employee, how would it be related to a specific task?

It seems like it would be a simple problem, but I can’t figure it out, and I should mention my database skills are rather rudimentary. So any help would be greatly appreciated!

EDIT:
Ok, several of you answered some variant on making a separate table for “Resources” with Employee_Id and Task_Id and WorkPercentage. But should I manually update the Employee_Id and Task_Id each time I add a task then? Because I first understood these answers as a hint that I should add a many-to-many relationship between Employee and Task and then add a field for WorkPercentage in the junction table (EmployeeTask). I tried that, but I immediately ran into problems when trying to add an employee, which demanded a list of EmployeeTasks and complained that there couldn’t be a null value for a non-nullable field. But that wasn’t how I should do it then? Rather a separate table manually updated with each field value…?

Please explain if possible exactly how to go about handling the solution several of you proposed (i.e. in terms of any relationships). Thanks!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T22:39:43+00:00Added an answer on May 19, 2026 at 10:39 pm

    Do you mean ‘Track how much of this task has been assigned to Employee A’?

    If so, you can create a new table that holds a task_id, an employee_id, and a percentage of the work.

    Cleanest way to handle it would be: Each time a new task is created add in a record with 100% assigned to no-one (e.g. employee id of 0). Then whenever someone gets assigned, create a new record for that employee and the % they’ve just been given and update the original record to take away that amount.

    That way you can also easily track any under-resourced tasks.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm working on a timesheet application. I'd like to add an autosave functionality. Let's
Our application has distribution functionality. It takes several Excel 2007 spreadsheets, copies them into
I have written an encoder for mpegts and I am trying to play it
Have the following scenario. I have a few form, which essentially have a few
have anyone found a substitution for RJS in Ruby on Rails for play? P.S.
have different files with same name, in different directories. In these files there are
Have an Action delegate and trying to use the ternary operator inside of it
Have a flash player that pops out into a separate popup browser window. And
Have String str May 23 2011 12:20:00, want to convert it to date such
I'm evaluating the use of CRM 2011 to replace one of our existing LOB

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.