Forum Discussion
Assistance Needed for Creating a New Column
- 2 years ago
Hi InsightSeeker - Here's how you can create a calculated column based on the given conditions
NewColumn =
IF (
OR (
'YourTableName'[settle name] = "Card",
'YourTableName'[settle name] = "OCCF"
) &&
'YourTableName'[code] = "000100160" &&
LEN('YourTableName'[number]) = 11 &&
LEFT('YourTableName'[number], 4) = "4398" &&
RIGHT('YourTableName'[number], 4) = "1614" &&
NOT ISBLANK('YourTableName'[code]),
"valid",
"error"
)you can replace 'YourTableName' with the actual name of your table, and 'settle name', 'code', and 'number' with the actual column names in your dataset.
Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!
Hi InsightSeeker - Here's how you can create a calculated column based on the given conditions
NewColumn =
IF (
OR (
'YourTableName'[settle name] = "Card",
'YourTableName'[settle name] = "OCCF"
) &&
'YourTableName'[code] = "000100160" &&
LEN('YourTableName'[number]) = 11 &&
LEFT('YourTableName'[number], 4) = "4398" &&
RIGHT('YourTableName'[number], 4) = "1614" &&
NOT ISBLANK('YourTableName'[code]),
"valid",
"error"
)
you can replace 'YourTableName' with the actual name of your table, and 'settle name', 'code', and 'number' with the actual column names in your dataset.
Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!