08-25-2016 10:56 AM - edited 08-25-2016 10:56 AM
I am trying to find multiples of ten between two variables. The way the edit is written is:
|CommittedBalance should not be multiple of 10 from prior quarter. For example, the prior quarter was 10 and the current quarter was 100. 100 / 10 = 10.|
I'm not sure how to check this. Is there a way to manipulate the mod(current,prior) function for this?
08-25-2016 11:13 AM
The mod function with a result of 0 only would tell you that the value was A multiple of the prior, could be any .
If you have the values easily to compare then
if current = 10* prior then <what ever>;
08-25-2016 11:21 AM
I guess something like:
flag = CommittedBalance ne lag(CommittedBalance) and (mod(CommittedBalance / lag(CommittedBalance), 10) = 0 or mod(lag(CommittedBalance) / CommittedBalance, 10) = 0);