erniewyles
Technical User
Ok, so here's what I am trying to do.
Firstly, I want to convert the person's current age to years and month, i.e. if the person is now 25 years and 3 months old, it is listed as 25.3.
But here's the twist, if the months are a particular number, they have to be changed according to the following table:
(Using the above example of 25 years and X months in 25.X format)
if month value is 0 then it is 0, i.e. 25.0 would remain 25.0
if month value is 1 then it is 1, i.e. 25.1 would remain 25.1
if month value is 2 then it is 2, i.e. 25.2 would remain 25.2
if month value is 3 then it is 3, i.e. 25.3 would remain 25.3
if month value is 4 then it is 3, i.e. 25.4 would be 25.3
if month value is 5 then it is 4, i.e. 25.5 would be 25.4
if month value is 6 then it is 5, i.e. 25.6 would be 25.5
if month value is 7 then it is 6, i.e. 25.7 would be 25.6
if month value is 8 then it is 7, i.e. 25.8 would be 25.7
if month value is 9 then it is 8, i.e. 25.9 would be 25.8
if month value is 10 then it is 8, i.e. 25.10 would be 25.8
if month value is 11 then it is 9, i.e. 25.11 would be 25.9
Firstly, I want to convert the person's current age to years and month, i.e. if the person is now 25 years and 3 months old, it is listed as 25.3.
But here's the twist, if the months are a particular number, they have to be changed according to the following table:
(Using the above example of 25 years and X months in 25.X format)
if month value is 0 then it is 0, i.e. 25.0 would remain 25.0
if month value is 1 then it is 1, i.e. 25.1 would remain 25.1
if month value is 2 then it is 2, i.e. 25.2 would remain 25.2
if month value is 3 then it is 3, i.e. 25.3 would remain 25.3
if month value is 4 then it is 3, i.e. 25.4 would be 25.3
if month value is 5 then it is 4, i.e. 25.5 would be 25.4
if month value is 6 then it is 5, i.e. 25.6 would be 25.5
if month value is 7 then it is 6, i.e. 25.7 would be 25.6
if month value is 8 then it is 7, i.e. 25.8 would be 25.7
if month value is 9 then it is 8, i.e. 25.9 would be 25.8
if month value is 10 then it is 8, i.e. 25.10 would be 25.8
if month value is 11 then it is 9, i.e. 25.11 would be 25.9