Forum Discussion
aszpic
9 years agoFrequent Visitor
Help on making a new column with a condition
Hello everyone, I couldn't find a way to do this: I have a table with 2 columns. The first column are some codes, which CAN be repeated. The 2nd column is a binary unmber (0/1). Example: CO...
- 9 years ago
Hi aszpic,
Firstly, I will set Number column to text to prevent it sum/count that column in table/matrix
Create Calculated column:
3rd = IF(CALCULATE(COUNT(Sheet1[Number]),filter(all(Sheet1),Sheet1[Number]="1" && Sheet1[CODES ]=EARLIER(Sheet1[CODES ]) ))>0,"1","0")
Earlier method to get current row, All method to select and compare in all rows in table
tringuyenminh92
Memorable Member
9 years agoHi aszpic,
Firstly, I will set Number column to text to prevent it sum/count that column in table/matrix
Create Calculated column:
3rd = IF(CALCULATE(COUNT(Sheet1[Number]),filter(all(Sheet1),Sheet1[Number]="1" && Sheet1[CODES ]=EARLIER(Sheet1[CODES ]) ))>0,"1","0")
Earlier method to get current row, All method to select and compare in all rows in table
- aszpic9 years agoFrequent Visitor
thanks a lot! It threw me an error because it can't compare numbers with text values, but with a little variation it worked perfectly.