<?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: Reordering Columns in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Reordering-Columns/m-p/42342#M179048</link>
    <description>&lt;P&gt;Thanks!  I looked at that, and didn't find what I needed.  But took a second look, and it had what I needed.  Thanks!&lt;/P&gt;

&lt;P&gt;I added this to the end:&lt;BR /&gt;
| table date, product, imps, clicks, category&lt;/P&gt;</description>
    <pubDate>Mon, 25 Feb 2013 17:49:03 GMT</pubDate>
    <dc:creator>nkitmitto</dc:creator>
    <dc:date>2013-02-25T17:49:03Z</dc:date>
    <item>
      <title>Reordering Columns</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Reordering-Columns/m-p/42340#M179046</link>
      <description>&lt;P&gt;How do I reorder the columns with this report?  I want it to be:&lt;BR /&gt;
 date - product - imps - clicks - category&lt;/P&gt;

&lt;P&gt;If I reorder the stats command, it fails and says :&lt;BR /&gt;
Error in 'stats' command: The argument 'date' is invalid.&lt;/P&gt;

&lt;P&gt;Here's the original query:&lt;/P&gt;

&lt;P&gt;sourcetype=imp-log host=*.prod.fb.local site_id=xxxx earliest=-1d@d latest=-0d@d&lt;BR /&gt;
| lookup siteproduct siteproductid as siteproduct_id siteid as site_id OUTPUTNEW productid as product productcategory as category&lt;BR /&gt;
| eval date = imp_date&lt;BR /&gt;
| stats count(eval(imp_action="imp")) as "imps", count(eval(imp_action="click")) as "clicks" by product, category, date&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 13:23:10 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Reordering-Columns/m-p/42340#M179046</guid>
      <dc:creator>nkitmitto</dc:creator>
      <dc:date>2020-09-28T13:23:10Z</dc:date>
    </item>
    <item>
      <title>Re: Reordering Columns</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Reordering-Columns/m-p/42341#M179047</link>
      <description>&lt;P&gt;&lt;A href="http://docs.splunk.com/Documentation/Splunk/latest/SearchReference/table"&gt;http://docs.splunk.com/Documentation/Splunk/latest/SearchReference/table&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 25 Feb 2013 17:46:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Reordering-Columns/m-p/42341#M179047</guid>
      <dc:creator>martin_mueller</dc:creator>
      <dc:date>2013-02-25T17:46:38Z</dc:date>
    </item>
    <item>
      <title>Re: Reordering Columns</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Reordering-Columns/m-p/42342#M179048</link>
      <description>&lt;P&gt;Thanks!  I looked at that, and didn't find what I needed.  But took a second look, and it had what I needed.  Thanks!&lt;/P&gt;

&lt;P&gt;I added this to the end:&lt;BR /&gt;
| table date, product, imps, clicks, category&lt;/P&gt;</description>
      <pubDate>Mon, 25 Feb 2013 17:49:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Reordering-Columns/m-p/42342#M179048</guid>
      <dc:creator>nkitmitto</dc:creator>
      <dc:date>2013-02-25T17:49:03Z</dc:date>
    </item>
    <item>
      <title>Re: Reordering Columns</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Reordering-Columns/m-p/42343#M179049</link>
      <description>&lt;P&gt;In using the table command, the order of the fields given will be the order of the columns in the table.&lt;/P&gt;

&lt;P&gt;For example, if I want my Error_Name to be before my Error_Count:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| table Error_Name, Error_Count
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;This would explicitly order the columns in the order I have listed here.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Sep 2020 17:52:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Reordering-Columns/m-p/42343#M179049</guid>
      <dc:creator>phastings</dc:creator>
      <dc:date>2020-09-29T17:52:46Z</dc:date>
    </item>
    <item>
      <title>Re: Reordering Columns</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Reordering-Columns/m-p/42344#M179050</link>
      <description>&lt;P&gt;This should also apply if you are running the query using the Java SDK, right? Because for me, even after specifying the order in the table command, the order in which results are returned is different.&lt;/P&gt;</description>
      <pubDate>Thu, 26 Dec 2019 04:57:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Reordering-Columns/m-p/42344#M179050</guid>
      <dc:creator>maggarwal28</dc:creator>
      <dc:date>2019-12-26T04:57:04Z</dc:date>
    </item>
  </channel>
</rss>

