Data manipulation on schedule or bank [closed]

0

Assuming I need to do the manipulation of a given example I get the weight and height of a user. I want to calculate her BMI to insert into the database. This BMI calculation must be done in a function in the code, or by a trigger in S.G.B.D

My boss who is manager of Information Management told me that this type of verification is done in B.D

But the teacher said that the correct thing is to do the calculation in the code and only send the data already ready to the bank

    
asked by anonymous 01.11.2018 / 18:09

1 answer

1

What's right or wrong always depends a lot on points of view.

What I recommend is that the data be stored in the database, and the entire business rule be done in code.

Because if you ever need to change databases, you will not have to change the business rule.

    
01.11.2018 / 19:26