<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Rename column using first row's value in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Rename-column-using-first-row-s-value/m-p/193914#M41474</link>
    <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm trying to name my column names based on the string word in the first&amp;nbsp;row of every other column as per described in the picture.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 999px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/16947i71F188209B9F80C7/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="Capture.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My script can't seem to work. I am finding a way to get the string value in the first row but doesn't seem to work. Can you help me out?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Consolas" size="1"&gt;dt = &lt;/FONT&gt;&lt;FONT color="#0000dd" face="Consolas" size="1"&gt;Current Data Table&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt;();&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Consolas" size="1"&gt;newname = dt &amp;lt;&amp;lt; &lt;/FONT&gt;&lt;FONT color="#000080" face="Consolas" size="1"&gt;select rows&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt; (&lt;/FONT&gt;&lt;FONT color="#008080" face="Consolas" size="1"&gt;1&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt;) &amp;lt;&amp;lt; &lt;/FONT&gt;&lt;FONT color="#000080" face="Consolas" size="1"&gt;print&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt; ;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000dd" face="Consolas" size="1"&gt;For&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt;( i = &lt;/FONT&gt;&lt;FONT color="#008080" face="Consolas" size="1"&gt;2&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt;, i &amp;lt;= &lt;/FONT&gt;&lt;FONT color="#0000dd" face="Consolas" size="1"&gt;N Cols&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt;( dt ), i=i+&lt;/FONT&gt;&lt;FONT color="#008080" face="Consolas" size="1"&gt;2&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000dd" face="Consolas" size="1"&gt;Column&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt;( dt, i+&lt;/FONT&gt;&lt;FONT color="#008080" face="Consolas" size="1"&gt;1&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt; ) &amp;lt;&amp;lt; &lt;/FONT&gt;&lt;FONT color="#000080" face="Consolas" size="1"&gt;Set Name&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt;( newname );&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;);&lt;/P&gt;&lt;P&gt;　&lt;/P&gt;&lt;P&gt;　&lt;/P&gt;&lt;P&gt;　&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 22 Apr 2019 10:38:27 GMT</pubDate>
    <dc:creator>Bryan</dc:creator>
    <dc:date>2019-04-22T10:38:27Z</dc:date>
    <item>
      <title>Rename column using first row's value</title>
      <link>https://community.jmp.com/t5/Discussions/Rename-column-using-first-row-s-value/m-p/193914#M41474</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm trying to name my column names based on the string word in the first&amp;nbsp;row of every other column as per described in the picture.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 999px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/16947i71F188209B9F80C7/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="Capture.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My script can't seem to work. I am finding a way to get the string value in the first row but doesn't seem to work. Can you help me out?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Consolas" size="1"&gt;dt = &lt;/FONT&gt;&lt;FONT color="#0000dd" face="Consolas" size="1"&gt;Current Data Table&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt;();&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Consolas" size="1"&gt;newname = dt &amp;lt;&amp;lt; &lt;/FONT&gt;&lt;FONT color="#000080" face="Consolas" size="1"&gt;select rows&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt; (&lt;/FONT&gt;&lt;FONT color="#008080" face="Consolas" size="1"&gt;1&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt;) &amp;lt;&amp;lt; &lt;/FONT&gt;&lt;FONT color="#000080" face="Consolas" size="1"&gt;print&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt; ;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000dd" face="Consolas" size="1"&gt;For&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt;( i = &lt;/FONT&gt;&lt;FONT color="#008080" face="Consolas" size="1"&gt;2&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt;, i &amp;lt;= &lt;/FONT&gt;&lt;FONT color="#0000dd" face="Consolas" size="1"&gt;N Cols&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt;( dt ), i=i+&lt;/FONT&gt;&lt;FONT color="#008080" face="Consolas" size="1"&gt;2&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000dd" face="Consolas" size="1"&gt;Column&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt;( dt, i+&lt;/FONT&gt;&lt;FONT color="#008080" face="Consolas" size="1"&gt;1&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt; ) &amp;lt;&amp;lt; &lt;/FONT&gt;&lt;FONT color="#000080" face="Consolas" size="1"&gt;Set Name&lt;/FONT&gt;&lt;FONT face="Consolas" size="1"&gt;( newname );&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;);&lt;/P&gt;&lt;P&gt;　&lt;/P&gt;&lt;P&gt;　&lt;/P&gt;&lt;P&gt;　&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 22 Apr 2019 10:38:27 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Rename-column-using-first-row-s-value/m-p/193914#M41474</guid>
      <dc:creator>Bryan</dc:creator>
      <dc:date>2019-04-22T10:38:27Z</dc:date>
    </item>
    <item>
      <title>Re: Rename column using first row's value</title>
      <link>https://community.jmp.com/t5/Discussions/Rename-column-using-first-row-s-value/m-p/193924#M41475</link>
      <description>&lt;P&gt;Try this script:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default to Here( 1 );

dt = Current Data Table()

For( c = 2, c &amp;lt; N Col( dt ), c += 2,
	Column( dt, c+1 ) &amp;lt;&amp;lt; Set Name( Column( dt, c )[1] );
);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 22 Apr 2019 11:26:49 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Rename-column-using-first-row-s-value/m-p/193924#M41475</guid>
      <dc:creator>Mark_Bailey</dc:creator>
      <dc:date>2019-04-22T11:26:49Z</dc:date>
    </item>
    <item>
      <title>Re: Rename column using first row's value</title>
      <link>https://community.jmp.com/t5/Discussions/Rename-column-using-first-row-s-value/m-p/902210#M106119</link>
      <description>&lt;P&gt;&lt;a href="https://community.jmp.com/t5/user/viewprofilepage/user-id/5358"&gt;@Mark_Bailey&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Works well.&amp;nbsp; You're missing a : after&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="jsl"&gt;dt = Current Data Table()&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Should be&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;dt = Current Data Table();&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Otherwise great&lt;/P&gt;</description>
      <pubDate>Fri, 19 Sep 2025 20:15:38 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Rename-column-using-first-row-s-value/m-p/902210#M106119</guid>
      <dc:creator>SpannerHead</dc:creator>
      <dc:date>2025-09-19T20:15:38Z</dc:date>
    </item>
    <item>
      <title>Re: Rename column using first row's value</title>
      <link>https://community.jmp.com/t5/Discussions/Rename-column-using-first-row-s-value/m-p/902220#M106122</link>
      <description>&lt;P&gt;in previous versions (&amp;lt;=18), one could use this workflow:&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;- duplicate the first row (we don't want to miss the entries in the next step)&lt;/P&gt;
&lt;P&gt;- use &lt;FONT face="courier new,courier"&gt;Cols/Column Names/move-up&lt;/FONT&gt; to use the duplicate 1st row as temporary column names&lt;/P&gt;
&lt;P&gt;- to shift the names by 1:&lt;BR /&gt;&amp;nbsp; &amp;nbsp;- copy the column temporary names via CTRL+C [done, but not visible in the video]&lt;BR /&gt;&amp;nbsp; &amp;nbsp;- delete the first column [otherwise name will be name2]&lt;BR /&gt;&amp;nbsp; &amp;nbsp;- mark the remaining columns&lt;BR /&gt;&amp;nbsp; &amp;nbsp;- paste the column names from the clipboard [please notice the change of the column names at the end]&lt;/P&gt;
&lt;P&gt;&lt;div class="lia-vid-container video-embed-center"&gt;&lt;div id="lia-vid-6379810577112w302h328r744" class="lia-video-brightcove-player-container"&gt;&lt;video-js data-video-id="6379810577112" data-account="6058004218001" data-player="default" data-embed="default" class="vjs-fluid" controls="" data-application-id="" style="width: 100%; height: 100%;"&gt;&lt;/video-js&gt;&lt;/div&gt;&lt;script src="https://players.brightcove.net/6058004218001/default_default/index.min.js"&gt;&lt;/script&gt;&lt;script&gt;(function() {  var wrapper = document.getElementById('lia-vid-6379810577112w302h328r744');  var videoEl = wrapper ? wrapper.querySelector('video-js') : null;  if (videoEl) {     if (window.videojs) {       window.videojs(videoEl).ready(function() {         this.on('loadedmetadata', function() {           this.el().querySelectorAll('.vjs-load-progress div[data-start]').forEach(function(bar) {             bar.setAttribute('role', 'presentation');             bar.setAttribute('aria-hidden', 'true');           });         });       });     }  }})();&lt;/script&gt;&lt;a class="video-embed-link" href="https://community.jmp.com/t5/video/gallerypage/video-id/6379810577112"&gt;(view in My Videos)&lt;/a&gt;&lt;/div&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 19 Sep 2025 20:58:09 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Rename-column-using-first-row-s-value/m-p/902220#M106122</guid>
      <dc:creator>hogi</dc:creator>
      <dc:date>2025-09-19T20:58:09Z</dc:date>
    </item>
  </channel>
</rss>

