# Promote a Row to be a Column Name

**URL:** <https://forum.knime.com/t/promote-a-row-to-be-a-column-name/17574>\
**Category:** KNIME Analytics Platform\
**Created:** [August 19, 2019, 9:50pm UTC](https://forum.knime.com/t/promote-a-row-to-be-a-column-name/17574 "2019-08-19T21:50:19Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ivannia](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/i/a587f6/32.png) [@Ivannia](https://forum.knime.com/u/Ivannia)\
**Post date:** [August 19, 2019, 9:50pm UTC](https://forum.knime.com/t/promote-a-row-to-be-a-column-name/17574/1 "2019-08-19T21:50:19Z")

</div>

Hi team,

I have a workflow very complicated, I’m working on it, but now I have the column names in the second row after use transpose node, so, how can I promote this row to be a column names

![image](https://forum-cdn.knime.com/uploads/default/original/2X/c/c517570e5fe5edb7ef17fda91e971bfbffa040b2.png)

Thanks in advance!!!

---

<div class="post-metadata">

**Author:** ![dnaki](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/d/a8b319/32.png) [@dnaki](https://forum.knime.com/u/dnaki)\
**Post date:** [August 20, 2019, 12:34am UTC](https://forum.knime.com/t/promote-a-row-to-be-a-column-name/17574/2 "2019-08-20T00:34:48Z")

</div>

Hi. I guess when you say “column names in the second row” you mean the first row of the table (under the column names?). If so, I created a metanode (now called a component) that promotes the first row of a table to column names. I use a Row Splitter to separate the first row from the rest of the table. Then I use a transpose node on the row with the col names to create a lookup table of column names. This is then fed into the Insert Column Header node. Please see attached workflow.  
Hope this helps.  
-Don  
 ![image](https://forum-cdn.knime.com/uploads/default/original/2X/5/5eae1ce13d700a509d467e4fda912be7d2da7b63.png)  
[promote first row to header.knwf](https://forum-cdn.knime.com/uploads/default/original/2X/e/ee55bed66e3bcdf31ca017bd53963170d19ef663.knwf) (12.3 KB)

---

<div class="post-metadata">

**Author:** ![Ivannia](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/i/a587f6/32.png) [@Ivannia](https://forum.knime.com/u/Ivannia)\
**Post date:** [August 20, 2019, 3:25pm UTC](https://forum.knime.com/t/promote-a-row-to-be-a-column-name/17574/5 "2019-08-20T15:25:34Z")

</div>

OMG!!! Thank you very much!!! Works perfectly!!!

---

<div class="post-metadata">

**Author:** ![JEMN](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/j/2bfe46/32.png) [@JEMN](https://forum.knime.com/u/JEMN)\
**Post date:** [August 26, 2019, 7:25pm UTC](https://forum.knime.com/t/promote-a-row-to-be-a-column-name/17574/6 "2019-08-26T19:25:35Z")

</div>

HI,

this is what I do to get any row become a column names.

![image](https://forum-cdn.knime.com/uploads/default/original/2X/2/2d0128a8d34d729e98960c8da9631f11eb833906.png)

In the RowID Node select de colum yo want to become column names.

 ![image](https://forum-cdn.knime.com/uploads/default/original/2X/0/0adf8adbd63bff7c223da6b582e199b8333d9367.png)

Check it out¡¡¡

Regards

---

<div class="post-metadata">

**Author:** ![Ivannia](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/i/a587f6/32.png) [@Ivannia](https://forum.knime.com/u/Ivannia)\
**Post date:** [August 26, 2019, 7:38pm UTC](https://forum.knime.com/t/promote-a-row-to-be-a-column-name/17574/7 "2019-08-26T19:38:17Z")

</div>

Nice idea!!! thanks a lot!!! 😉

---

<div class="post-metadata">

**Author:** ![system](https://forum-cdn.knime.com/uploads/default/original/1X/ab3ccf34482a0329361734a18199390177204f15.png) [@system](https://forum.knime.com/u/system)\
**Post date:** [September 2, 2019, 7:38pm UTC](https://forum.knime.com/t/promote-a-row-to-be-a-column-name/17574/8 "2019-09-02T19:38:21Z")

</div>

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.
