<?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 Re: Looking for the column number? in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18797#M17127</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Oh thank you for catching that!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My code is working well, thanks again.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 25 May 2016 18:44:50 GMT</pubDate>
    <dc:creator>natalie_</dc:creator>
    <dc:date>2016-05-25T18:44:50Z</dc:date>
    <item>
      <title>Looking for the column number?</title>
      <link>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18794#M17124</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need the column number.&amp;nbsp; I have the name of the column, but it might not always be in the same space.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I first decided to use a While loop which stops iterating when the column is found.&amp;nbsp; "n" would be the column number, but it isn't working.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;colFound &lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt; &lt;STRONG style="color: teal; font-family: Consolas;"&gt;0&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;n&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-family: Consolas;"&gt;0&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: #0000dd;"&gt;While&lt;/SPAN&gt;&lt;STRONG style="color: black; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;colFound &lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;==&lt;/SPAN&gt; &lt;STRONG style="color: teal; font-family: Consolas;"&gt;0&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; n&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;++;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; colName &lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt; &lt;SPAN style="font-family: Consolas; color: #0000dd;"&gt;Column Name&lt;/SPAN&gt;&lt;STRONG style="color: black; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;n&lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-family: Consolas; color: #0000dd;"&gt;if&lt;/SPAN&gt;&lt;STRONG style="color: black; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;colName&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;==&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;Vd&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt; colFound&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-family: Consolas;"&gt;1&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt; &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: black; font-family: Consolas;"&gt;)&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: Consolas; color: #333333;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: Consolas; color: #333333;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: arial, helvetica, sans-serif;"&gt;I get this error:&amp;nbsp; invalid argument in access or evaluation of 'Column Name' , Column Name/*###*/(n)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: Consolas;"&gt;However, if I use this (this one time I know the actual number) it returns the column name I am looking for:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;col = Column Name(38);&lt;/P&gt;&lt;P&gt;show(col);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;From a post (&lt;A href="https://community.jmp.com/message/228185" target="_blank"&gt;column number&lt;/A&gt;) , I used msharp's suggestion, but still no luck on getting the column number, it just returns the column name?&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Oct 2016 13:27:12 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18794#M17124</guid>
      <dc:creator>natalie_</dc:creator>
      <dc:date>2016-10-28T13:27:12Z</dc:date>
    </item>
    <item>
      <title>Re: Looking for the column number?</title>
      <link>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18795#M17125</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;column name is misleading - it returns the column, e.g. :height, and not "height".&amp;nbsp; Also you never check to see if n goes beyond the number of columns in your table.&amp;nbsp; This code will work:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;dt &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;=&lt;/SPAN&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: #0000dd;"&gt;Open&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: 'Courier New';"&gt;(&lt;/STRONG&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: purple;"&gt;"$sample_data\Big Class.jmp"&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: #0000dd;"&gt;Current Data Table&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: 'Courier New';"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; dt &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;vd &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;=&lt;/SPAN&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: purple;"&gt;"height"&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;colFound &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;=&lt;/SPAN&gt; &lt;STRONG style="color: teal; font-size: 10.0pt; font-family: 'Courier New';"&gt;0&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;n &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;=&lt;/SPAN&gt; &lt;STRONG style="color: teal; font-size: 10.0pt; font-family: 'Courier New';"&gt;0&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;ncols &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;=&lt;/SPAN&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: #0000dd;"&gt;ncol&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: 'Courier New';"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;dt&lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: #0000dd;"&gt;While&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: 'Courier New';"&gt;(&lt;/STRONG&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;!&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;colFound &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;&amp;amp;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; n &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;&amp;lt;=&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; ncols&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; n&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;++;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; colName &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; &lt;STRONG&gt;(&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: #0000dd;"&gt;Column Name&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: 'Courier New';"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; n &lt;STRONG&gt;)&lt;/STRONG&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;&amp;lt;&amp;lt;&lt;/SPAN&gt; &lt;STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;get name&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;)&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: #0000dd;"&gt;If&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: 'Courier New';"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; colName &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;==&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; Vd&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; colFound &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;=&lt;/SPAN&gt; &lt;STRONG style="color: teal; font-size: 10.0pt; font-family: 'Courier New';"&gt;1&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: 'Courier New';"&gt;)&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 May 2016 18:09:47 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18795#M17125</guid>
      <dc:creator>pmroz</dc:creator>
      <dc:date>2016-05-25T18:09:47Z</dc:date>
    </item>
    <item>
      <title>Re: Looking for the column number?</title>
      <link>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18796#M17126</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;For some reason the while loop was not working properly if the column name is not found.&amp;nbsp; This is a bit cleaner:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;dt &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;=&lt;/SPAN&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: #0000dd;"&gt;Open&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: 'Courier New';"&gt;(&lt;/STRONG&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: purple;"&gt;"$sample_data\Big Class.jmp"&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: #0000dd;"&gt;Current Data Table&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: 'Courier New';"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; dt &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;vd &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;=&lt;/SPAN&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: purple;"&gt;"height"&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;colFound &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;=&lt;/SPAN&gt; &lt;STRONG style="color: teal; font-size: 10.0pt; font-family: 'Courier New';"&gt;0&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;n &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;=&lt;/SPAN&gt; &lt;STRONG style="color: teal; font-size: 10.0pt; font-family: 'Courier New';"&gt;0&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;ncols &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;=&lt;/SPAN&gt; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: #0000dd;"&gt;ncol&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: 'Courier New';"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;dt&lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: #0000dd;"&gt;for&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; &lt;STRONG&gt;(&lt;/STRONG&gt;i &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;=&lt;/SPAN&gt; &lt;STRONG style="color: teal; font-size: 10.0pt; font-family: 'Courier New';"&gt;1&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; i &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;&amp;lt;=&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; ncols&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; i&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;++,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; colName &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; &lt;STRONG&gt;(&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: #0000dd;"&gt;Column Name&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: 'Courier New';"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; i &lt;STRONG&gt;)&lt;/STRONG&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;&amp;lt;&amp;lt;&lt;/SPAN&gt; &lt;STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;get name&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;)&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: #0000dd;"&gt;If&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: 'Courier New';"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; colName &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;==&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt; Vd&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; colFound &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;=&lt;/SPAN&gt; &lt;STRONG style="color: teal; font-size: 10.0pt; font-family: 'Courier New';"&gt;1&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: #0000dd;"&gt;break&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: 'Courier New';"&gt;()&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: 'Courier New';"&gt;)&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: 'Courier New'; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 May 2016 18:19:09 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18796#M17126</guid>
      <dc:creator>pmroz</dc:creator>
      <dc:date>2016-05-25T18:19:09Z</dc:date>
    </item>
    <item>
      <title>Re: Looking for the column number?</title>
      <link>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18797#M17127</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Oh thank you for catching that!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My code is working well, thanks again.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 May 2016 18:44:50 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18797#M17127</guid>
      <dc:creator>natalie_</dc:creator>
      <dc:date>2016-05-25T18:44:50Z</dc:date>
    </item>
    <item>
      <title>Re: Looking for the column number?</title>
      <link>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18798#M17128</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It looks like Peter beat me to responding, but here's another method without any loops, so it should be faster for a large number of columns.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; &lt;SPAN class="s1" style="font-size: 10pt; line-height: 1.5em;"&gt;dt = &lt;/SPAN&gt;&lt;SPAN class="s2" style="font-size: 10pt; line-height: 1.5em;"&gt;Open&lt;/SPAN&gt;&lt;SPAN class="s1" style="font-size: 10pt; line-height: 1.5em;"&gt;( &lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;"$sample_data\Analgesics.jmp"&lt;/SPAN&gt;&lt;SPAN class="s1" style="font-size: 10pt; line-height: 1.5em;"&gt; );&lt;/SPAN&gt;&lt;/P&gt;&lt;P class="p2"&gt;column_number = &lt;SPAN class="s2"&gt;Contains&lt;/SPAN&gt;(dt &amp;lt;&amp;lt; &lt;SPAN class="s3"&gt;get column names&lt;/SPAN&gt;, &lt;SPAN class="s2"&gt;Column&lt;/SPAN&gt;(&lt;SPAN class="s4"&gt;"drug"&lt;/SPAN&gt;));&lt;/P&gt;&lt;P class="p3"&gt;&lt;/P&gt;&lt;P class="p3"&gt;Just replace "drug" with whatever column name you're searching for to get the associated column number.&lt;/P&gt;&lt;P class="p3"&gt;&lt;/P&gt;&lt;P class="p3"&gt;&lt;A href="https://community.jmp.com/people/julian"&gt;julian&lt;/A&gt;​&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 May 2016 18:57:09 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18798#M17128</guid>
      <dc:creator>jules</dc:creator>
      <dc:date>2016-05-25T18:57:09Z</dc:date>
    </item>
    <item>
      <title>Re: Looking for the column number?</title>
      <link>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18799#M17129</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks, glad you posted!&amp;nbsp; I got it working.&amp;nbsp; Now I understand a little more from both your posts &lt;SPAN __jive_emoticon_name="happy" __jive_macro_name="emoticon" class="jive_emote jive_macro" src="https://community.jmp.com/7.0.4.3b79b96/images/emoticons/happy.png"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 May 2016 19:03:37 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18799#M17129</guid>
      <dc:creator>natalie_</dc:creator>
      <dc:date>2016-05-25T19:03:37Z</dc:date>
    </item>
    <item>
      <title>Re: Looking for the column number?</title>
      <link>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18800#M17130</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think you miss understood my suggestion.&amp;nbsp; My suggestion is that you should NOT find a column number.&amp;nbsp; It's poor coding practice, in fact it's horrendous. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 May 2016 19:47:40 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18800#M17130</guid>
      <dc:creator>msharp</dc:creator>
      <dc:date>2016-05-25T19:47:40Z</dc:date>
    </item>
    <item>
      <title>Re: Looking for the column number?</title>
      <link>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18801#M17131</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If I know there will always be a column named "Vd" in my data but it could be in a different location each time, why wouldn't I want to use the column number?&amp;nbsp; After the Vd column, there will be "x" number of columns that I need to insert into a list.&amp;nbsp; Since the number of columns is unknown until after I run the script and the names of these columns will be determined based on the result of my data, I don't see why using the column number is horrendous.&amp;nbsp; I suppose as those columns are being created I could insert those into a list, but please explain why getting the column number is horrendous?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;colFound &lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt; &lt;STRONG style="color: teal; font-family: Consolas;"&gt;0&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;n&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-family: Consolas;"&gt;0&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;ncols &lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt; &lt;SPAN style="font-family: Consolas; color: #0000dd;"&gt;ncol&lt;/SPAN&gt;&lt;STRONG style="color: black; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;dtSummary&lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: #0000dd;"&gt;for&lt;/SPAN&gt;&lt;STRONG style="color: black; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;i&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-family: Consolas;"&gt;1&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt; i&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;&amp;lt;=&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;ncols&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt; i&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;++,&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; colName &lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt; &lt;STRONG&gt;(&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: #0000dd;"&gt;Column Name&lt;/SPAN&gt;&lt;STRONG style="color: black; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;i&lt;STRONG&gt;)&lt;/STRONG&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;&amp;lt;&amp;lt;&lt;/SPAN&gt; &lt;STRONG&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;get name&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;)&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-family: Consolas; color: #0000dd;"&gt;if&lt;/SPAN&gt;&lt;STRONG style="color: black; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;colName&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;==&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: purple;"&gt;"Vd"&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt; colFound&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-family: Consolas;"&gt;1&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt; &lt;SPAN style="font-family: Consolas; color: #0000dd;"&gt;break&lt;/SPAN&gt;&lt;STRONG style="color: black; font-family: Consolas;"&gt;()&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt; &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;STRONG style="color: black; font-family: Consolas;"&gt;)&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;iCol &lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt; &lt;STRONG style="color: teal; font-family: Consolas;"&gt;1&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-family: Consolas; color: green;"&gt;//iCol = Contains(dtSummary &amp;lt;&amp;lt; get column names, Column("Vd"));&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: #0000dd;"&gt;if&lt;/SPAN&gt;&lt;STRONG style="color: black; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;colFound &lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;==&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-family: Consolas;"&gt;1&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; y_cols &lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt; &lt;STRONG&gt;{}&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-family: Consolas; color: #0000dd;"&gt;for&lt;/SPAN&gt;&lt;STRONG style="color: black; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;n&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;iCol&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;+&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-family: Consolas;"&gt;1&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt; n&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;&amp;lt;=&lt;/SPAN&gt;&lt;STRONG style="color: black; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;iCol&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;+&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt; devicePass&lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt; n&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;++,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; y_cols &lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt; &lt;SPAN style="font-family: Consolas; color: #0000dd;"&gt;Insert&lt;/SPAN&gt;&lt;STRONG style="color: black; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;y_cols&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt; n&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt; n&lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Consolas; color: navy;"&gt;,);&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 May 2016 20:18:12 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18801#M17131</guid>
      <dc:creator>natalie_</dc:creator>
      <dc:date>2016-05-25T20:18:12Z</dc:date>
    </item>
    <item>
      <title>Re: Looking for the column number?</title>
      <link>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18802#M17132</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just as a rule of thumb.&amp;nbsp;&amp;nbsp; I would say, if your code or table is set up in such a way that it depends on column order, you are probably doing something ugly.&amp;nbsp; It might work, but there is probably a more elegant, faster way to do it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Order of data should really only be considered at the end of a script when you choose to display the data (and for the most part that's not even necessary since it's usually better to show the data in a graph and not in a table).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This being said, ugly code that works is still good code.&amp;nbsp; In your case, assuming you have no control of how the data-tables are being fed into your script this may be the simplest solution.&amp;nbsp; However, you could still condense the code like so:&amp;nbsp; (Notice how I never need to know the column number).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt;colFound &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt; &lt;STRONG style="color: teal; font-size: 10.0pt; font-family: Consolas;"&gt;0&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt;ncols &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt; &lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: #0000dd;"&gt;ncol&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt;dtSummary&lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: #0000dd;"&gt;for&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt;i&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt;&lt;STRONG style="color: teal; font-size: 10.0pt; font-family: Consolas;"&gt;1&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt; i&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;&amp;lt;=&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt;ncols&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt; i&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;++,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: #0000dd;"&gt;if&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt;colFound&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: #0000dd;"&gt;if&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt;devicePass&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; devicePass&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;--;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: #0000dd;"&gt;Insert Into&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt;y_cols&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt; i&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt; i&lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: #0000dd;"&gt;break&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: Consolas;"&gt;()&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;)&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; colName &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt; &lt;STRONG&gt;(&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: #0000dd;"&gt;Column Name&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt;i&lt;STRONG&gt;)&lt;/STRONG&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;&amp;lt;&amp;lt;&lt;/SPAN&gt; &lt;STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;get name&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt;)&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: #0000dd;"&gt;if&lt;/SPAN&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: Consolas;"&gt;(&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt;colName&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;==&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: purple;"&gt;"Vd"&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt; colFound&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;=&lt;/SPAN&gt;&lt;STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: teal;"&gt;1&lt;/SPAN&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: black;"&gt;)&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="color: black; font-size: 10.0pt; font-family: Consolas;"&gt;)&lt;/STRONG&gt;&lt;SPAN style="font-size: 10.0pt; font-family: Consolas; color: navy;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 May 2016 21:59:08 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18802#M17132</guid>
      <dc:creator>msharp</dc:creator>
      <dc:date>2016-05-25T21:59:08Z</dc:date>
    </item>
    <item>
      <title>Re: Looking for the column number?</title>
      <link>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18803#M17133</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you msharp, I will keep this in mind.&amp;nbsp; It is way cleaner!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 26 May 2016 13:44:23 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Looking-for-the-column-number/m-p/18803#M17133</guid>
      <dc:creator>natalie_</dc:creator>
      <dc:date>2016-05-26T13:44:23Z</dc:date>
    </item>
  </channel>
</rss>

