- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Populate new column based on values of another column
I'd like to do something like an Excel VLOOKUP ---- where I'd like to populate an empty new column (New_Status) with values from the original column (STATUS) --- but some of the values need to be translated.... many of the original status entries do not state explicitly that the item is 'Open' but for my purposes they are open.... so I'd like a column that consolidates all the text that means 'open' to the word 'open...
Original Column: Translate to this new Column:
STATUS | New_Status | |
Closed | Closed | |
Pending Group Discussion | Open | |
Open | Open | |
Open | Open | |
Closed | ----> Translate to this column ---> | Closed |
Rejected | Rejected | |
Open | Open | |
Open | Open | |
Ready to Deploy to QA | Open | |
Ready to Deploy to QA | Open | |
Ready to Deploy to QA | Open | |
QA Testing In Progress (on QA Platform) | Open | |
Open | Open | |
Resolved | Resolved | |
Open | Open | |
Ready to Deploy to QA | Open | |
Open | Open | |
Ready to Deploy to QA | Open |
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: Populate new column based on values of another column
You can create a column formula for this. You'll have to keep it up to date with valid Open values. Assuming that dt points to your table:
dt << New Column( "New Status Formula", Character, Nominal,
Formula(If (:STATUS == "Open" |
:STATUS == "Pending Group Discussion" |
:STATUS == "Ready to Deploy to QA" |
:STATUS == "QA Testing In Progress (on QA Platform)",
// then
"Open",
// else
:STATUS
)
)
);
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: Populate new column based on values of another column
You can create a column formula for this. You'll have to keep it up to date with valid Open values. Assuming that dt points to your table:
dt << New Column( "New Status Formula", Character, Nominal,
Formula(If (:STATUS == "Open" |
:STATUS == "Pending Group Discussion" |
:STATUS == "Ready to Deploy to QA" |
:STATUS == "QA Testing In Progress (on QA Platform)",
// then
"Open",
// else
:STATUS
)
)
);
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: Populate new column based on values of another column
An alternative to If() is the Match() function that may be easier to maintain if the non-open statuses are static and few
The formula below returns "Open" for all except for "Closed", "Rejected" and "Resolved".
Match( :STATUS,
"Closed", "Closed",
"Rejected", "Rejected",
"Resolved", "Resolved",
"Open"
)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: Populate new column based on values of another column
PM --- THANK YOU ----- for your quick response and it works perfectly ------