gpt-3.5-turbo-0613· OpenAI
WildChat-4.8M (AI2)
There appears to be an error in this formual: =IF(AND(ISTEXT(TRIM(C2)),…
- User
There appears to be an error in this formual: =IF(AND(ISTEXT(TRIM(C2)), LEFT(TRIM(C2),4)=LEFT(TRIM(2:22),4)),1,0)
- Assistant
The error in this formula is that you cannot use a cell range (e.g., 2:22) inside the LEFT function. The LEFT function only works with individual cells or single values, not ranges.
To fix this error, you need to use an array formula or a helper column to check each cell in the range individually. Here is an example of using a helper column:
- Insert a new column next to column Y.
- In the first cell of the new column (let's say Z2), enter the formula: =IF(AND(ISTEXT(TRIM(C2)), LEFT(TRIM(C2), 4) = LEFT(TRIM(Y2), 4)), 1, 0)
- Drag the formula down to fill the entire range (Z2:Z22).
- Now you can use the SUM function or any other calculation on the helper column to get the desired result.