Skip to content
Advertisement

Constraints using If structure

I got a data table and require some custom constraints. The data table is as following: ID int Val_1 int Val_2 int Val_3 int What i need is the following: If (Val_1 == A) { Val_2 cant be …

SQL – Get previous amounts for each day

I’m trying to write a query that is sort of like a running total but not really. I want to get the previous weight (kg) and keep outputting that for each day until another weight (kg) is recorded then …

Advertisement