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 7759431
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T13:37:37+00:00 2026-06-01T13:37:37+00:00

I have a seemingly simple problem, but I can’t quite figure out a solution.

  • 0

I have a seemingly simple problem, but I can’t quite figure out a solution. I am creating a database design to store goals. The goals are updated manually, and I need an entry each time the goal is updated. For Example:

Lose 10 pounds:

Day 1: lost 1 pound.
Day 3: lost 2 pounds.
day 7: lost 7 pounds.

And then once the total of the pounds reaches the goal amount, that goal is completed. Here is my design so far, but I am seeing some issues with it:

Goals Table:

GoalId – int – PK

UserId = int – FK

GoalTypeId = int – FK

Title – string

Progress Table:

ProgressId – int – PK

GoalId – int – FK

IntervalX – string?

IntervalY – string?

GoalAmount – String?

Is this the best way to track this? Has anyone seen a base schema out there I can build off of to accomplish this?

Another thought I had was maybe use this design for all my raw data, and rely on stored procedure and views to present the data in the way I want it?

EDIT:

Sorry, I will elaborate a bit. Interval X and Y are going to be what the interval values are on a graph. So if X = 1 and Y = 10 then the x axis will go 1,2,3,… and Y will go 10,20,30,… (This is something else entirely I need to figure out the best way to implement, but that’s on the backburner for now)

Types of goals are tricky since there are many I would like to do. They will need to be a bunch of different data types:

Examples of goals:

Read daily – boolean

lose 10 pound – int or float

save $5000 – money or float

hit sales quota – float

Learn a new language – string? (not sure the best way to track this one)

And so on.. Hope this helps clarify a bit

  • 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-06-01T13:37:39+00:00Added an answer on June 1, 2026 at 1:37 pm

    You’re certianly on the right track. The only other thing I can recommend is looking into key value indicators, and using this principle in your design. KVIs (or KPIs, as they’re referred to in management) are values of disparate sources, which are converted into a common set of values that can be processed using common logic. This will help with evaulating progress on goals that have milestones of different types, and for compound goals, this is a crucial step. I’ll elaborate a bit on this:

    A goal is defined as reaching a certain milestone or combination of milestones within a certain period. The milestone is the value the needs to have a common processing value, or key value indiator. For example, losing 10 pounds, you could have a key value type of “Weight Loss”, converting 1 pound to 1 KVI. Where you wish to compare milestones with one another, you may wish to adjust the weights. For example, I wish to become fitter and feel more energetic (goal). In order to do this, I must lose 10 pounds, cut sugar from my diet and cycle at least 15 miles per day (milestones). When comparing these values, 1 mile does not equate to 1 pound. More like 30 miles. Cutting sugar from my diet is not easy, but let’s call the KVI “Days without sugar”, and give each day without sugar a value equivalent to half a pound. The KVIs are then:

    1 pound = 2 KVI
    1 day without sugar = 1 KVI
    1 mile = 1/30 KVI
    

    If I ride an extra 15 miles per day, I can probably forgive myself a little bit of sugar, so this should be built into the milestones. In other words, I can achieve 200% of my cycling milestone and only 75% of my sugar milestone, and still achieve my overall goal. However, I can’t go over that and still expect to feel healthy. My milestone for this goal would therefore look something like:

    Lose 10 pounds: KVIType="Weight Loss", Target=20KVI, cap=100%
    No sugar for period (let's say 2 weeks):KVIType="Days without sugar", target=14KVI, cap=100%
    Cycle 15 miles per day: KVIType="Cycling", target=7KVI, cap=200%
    

    Learning a new language is a good example. This requires learning the grammatical nuances of the language, sometimes a different alphabet, a whole new vocabulary and then tying these all together into daily use. So here’s an example:

    Learn language grammar = 100 KVI, which you can work as a percentage of a grammar course completed, for example
    1000 words vocabulary = 100 KVI
    Conversation = 20 KVI
    

    In this example, you would cap each milestone at 100%. You may know the grammar off by heart and have 10,000 words under your belt, but until you’ve spent some time speaking the language, you haven’t learned it.

    By adjusting the weights in your conversion table, you can start comparing goals with one another in a way that makes sense to you. I can afford to lose 10 pounds but don’t need to, so I wouldn’t put too high a price tag on that one. My friend Luka, however, is 100 pounds overweight and has to for health reasons, so he’d have a higher KVI value for that one. You can also expand on how the milestones are combined to provide a progress indication of the goal (i.e. using the sum of all KVIs, average or minimum percentage completed for any component milestone).

    This is sort of what I had in mind:

    CREATE TABLE KVIType (
        KVITypeId INT IDENTITY(1, 1) PRIMARY KEY CLUSTERED,
        KVIName VARCHAR(50),
        Description VARCHAR(200),
        Multiplier DOUBLE PRECISION
    )
    
    CREATE TABLE Goal (
        GoalId INT IDENTITY(1, 1) PRIMARY KEY CLUSTERED,
        UserId INT FOREIGN KEY REFERENCES User(UserId),
        GoalName VARCHAR(50),
        GoalStart DATETIME,
        GoalComplete DATETIME,
        TargetKVI DOUBLE PRECISION,
        CurrentKVI DOUBLE PRECISION
    )
    
    CREATE TABLE Milestone (
        MilestoneId INT IDENTITY(1,1) PRIMARY KEY CLUSTERED,
        GoalId INT FOREIGN KEY REFERENCES Goal(GoalId),
        KVITypeId INT FOREIGN KEY REFERENCES KVIType(KVITypeId),
        MilestoneName VARCHAR(50),
        Description VARCHAR(200),
        TargetKVI DOUBLE PRECISION,
        CurrentKVI DOUBLE PRECISION,
        TargetDate DATETIME,
        CompletedDate DATETIME,
        Cap INT)
    
    CREATE TABLE Progress (
        ProgressId INT IDENTITY(1, 1) PRIMARY KEY CLUSTERED,
        MilestoneID INT FOREIGN KEY REFERENCES Milestone(MilestoneId),
        InputValue DOUBLE PRECISIoN,
        KVIValue DOUBLE PRECISION,
        OccuranceDate DATETIME
    )
    
    CREATE TABLE User (
        UserId INT IDENTITY(1, 1) PRIMARY KEY CLUSTERED,
        UserName VARCHAR(100)
    )
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i'm trying to solve a seemingly simple problem, but just can't quite get my
I'm running in to a seemingly simple problem, but can't seem to get around
I have a seemingly simple problem whereby I wish to reconcile two lists so
While I have the problem itself seemingly resolved, I'm hoping someone can shed some
I'm stuck on a RegEx problem that's seemingly very simple and yet I can't
I'm stumped by a seemingly simple problem. In my ASP.NET page, I have a
I have a problem which appears when using Ubuntu Linux/Gnome, but seemingly not on
Good day once again. I have a (seemingly) simple problem. I'm trying to display
I have been trying to get this seemingly simple problem fixed for about half
Howdy, codeboys and codegirls! I have came across a simple problem with seemingly easy

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.