AnsweredAssumed Answered

Find First 1 in a row

Question asked by clintoncooper on Oct 17, 2013
Latest reply on Oct 18, 2013 by clintoncooper
Hello,

I am looking for a script that I can use to find the first 1 in a row of say ten or so fields, and then return something that indicates which field that first one showed up in. 

I have a data set of fields for each year and to mark if an event happened in that year it has a 1.  If the event did not happen in that year it is marked with a 0.  I can set the years to be in any order (from oldest to newest or vice versa). 

Ideally I would like to be able to say that if in year 2000, the value to be retuned would be 13  (year 2013 - year 2000). 

Clinton

Outcomes