<?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: Refer to a field in table by its position in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Refer-to-a-field-in-table-by-its-position/m-p/397487#M115377</link>
    <description>&lt;P&gt;Nope, this will group everything up in one cell which is not the desired outcome &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 16 Jul 2019 04:47:47 GMT</pubDate>
    <dc:creator>nabeel652</dc:creator>
    <dc:date>2019-07-16T04:47:47Z</dc:date>
    <item>
      <title>Refer to a field in table by its position</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Refer-to-a-field-in-table-by-its-position/m-p/397485#M115375</link>
      <description>&lt;P&gt;Wondering if we can do something like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;... | table * | sort by &amp;lt;1&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Where  &lt;CODE&gt;&amp;lt;1&amp;gt;&lt;/CODE&gt;  refers to the first field in the table as the field names are dynamic and subject to change.&lt;/P&gt;</description>
      <pubDate>Tue, 16 Jul 2019 03:51:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Refer-to-a-field-in-table-by-its-position/m-p/397485#M115375</guid>
      <dc:creator>nabeel652</dc:creator>
      <dc:date>2019-07-16T03:51:49Z</dc:date>
    </item>
    <item>
      <title>Re: Refer to a field in table by its position</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Refer-to-a-field-in-table-by-its-position/m-p/397486#M115376</link>
      <description>&lt;P&gt;Try this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; | stats values(*) as * | sort 0 *
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 16 Jul 2019 04:25:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Refer-to-a-field-in-table-by-its-position/m-p/397486#M115376</guid>
      <dc:creator>jkat54</dc:creator>
      <dc:date>2019-07-16T04:25:33Z</dc:date>
    </item>
    <item>
      <title>Re: Refer to a field in table by its position</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Refer-to-a-field-in-table-by-its-position/m-p/397487#M115377</link>
      <description>&lt;P&gt;Nope, this will group everything up in one cell which is not the desired outcome &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 16 Jul 2019 04:47:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Refer-to-a-field-in-table-by-its-position/m-p/397487#M115377</guid>
      <dc:creator>nabeel652</dc:creator>
      <dc:date>2019-07-16T04:47:47Z</dc:date>
    </item>
    <item>
      <title>Re: Refer to a field in table by its position</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Refer-to-a-field-in-table-by-its-position/m-p/397488#M115378</link>
      <description>&lt;P&gt;If the order of field names is acceptable&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; ... | table * |sort [search (your search)|head 1 | table * | stats dc(*) as * | transpose |head 1|rename column as query]
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 16 Jul 2019 05:52:20 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Refer-to-a-field-in-table-by-its-position/m-p/397488#M115378</guid>
      <dc:creator>HiroshiSatoh</dc:creator>
      <dc:date>2019-07-16T05:52:20Z</dc:date>
    </item>
    <item>
      <title>Re: Refer to a field in table by its position</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Refer-to-a-field-in-table-by-its-position/m-p/397489#M115379</link>
      <description>&lt;P&gt;Awesome, that worked. Can you please explain this? &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| rename column as query
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 16 Jul 2019 06:12:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Refer-to-a-field-in-table-by-its-position/m-p/397489#M115379</guid>
      <dc:creator>nabeel652</dc:creator>
      <dc:date>2019-07-16T06:12:43Z</dc:date>
    </item>
    <item>
      <title>Re: Refer to a field in table by its position</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Refer-to-a-field-in-table-by-its-position/m-p/397490#M115380</link>
      <description>&lt;P&gt;The return value will be the value only. Usually field = value.&lt;/P&gt;

&lt;P&gt;special field：query&lt;/P&gt;

&lt;P&gt;index=* [inputlookup xxx.csv | fields col_a]&lt;BR /&gt;
-&amp;gt;(col_a=1) OR (col_a=2) OR (col_a=3) ・・・・&lt;/P&gt;

&lt;P&gt;index=* [inputlookup xxx.csv | rename  col_a as query  | fields query]&lt;BR /&gt;
-&amp;gt;(1) OR (2) OR (3) ・・・・&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 01:22:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Refer-to-a-field-in-table-by-its-position/m-p/397490#M115380</guid>
      <dc:creator>HiroshiSatoh</dc:creator>
      <dc:date>2020-09-30T01:22:59Z</dc:date>
    </item>
  </channel>
</rss>

