For each row entered, the user will have one piece of data in either grams, kilograms or pounds.  I supply 3 fields and the user must enter in one. The app then calculates the other two values off the entered value.I am wondering if it is best practice to store all 3 values in the database, or just store the single value entered and calculate the other 2 as needed for display and reporting purposes.
Best practice when dealing and storing calculated data
architecture
For data this simple to calculate, it does not make sense to store denormalized data (all three).Store only the grams and user in the database, then load the user and grams properties of this object with the stored data.public class Weight{     public string User {get;set;}     public double Grams {get;set;}     public double KG      {         get { return Grams * .001; }         set { Grams = value * 1000.0;}     }     public double Pounds     {          get { return Grams * 0.00220462; }         set { Grams = value * 453.592; }     }}and for storage, we can see the benefits of the repository pattern for cases like this where our optimal storage solution does not resemble our business use case:public class WeightRepository{      public void Insert(Weight weight)      {          sqlConnection.Execute(insert into Weight (User, Grams) values (@user, @grams), weight.User, weight.Grams);      }      //Get, update, ect}With this approach, our business logic (Weight class) is isolated, convenient to use, and easily unit tested.We can also get blazing fast reads from our DB since we have minimized our number of columns.Usually, good architecture increases performance, not hinders it :)