<?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: Getting Duplicate message when doing search for User ID (title) in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Getting-Duplicate-message-when-doing-search-for-User-ID-title/m-p/410322#M168681</link>
    <description>&lt;P&gt;@nls7010 can you share the Simple XML code for Dropdown which is throwing Duplicate Values error? (Use the &lt;CODE&gt;code button i.e. 101010&lt;/CODE&gt; or &lt;CODE&gt;Ctrl + K&lt;/CODE&gt; while posting code so that special characters do not escape.&lt;/P&gt;

&lt;P&gt;Also better way to run the same query would be as follows:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| rest /services/authentication/users splunk_server=local 
| fields title 
| dedup title 
| rename title as user 
| sort user
| table user
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;For reference, following is a previous run anywhere example code of mine which would get the logged in User's Role and then show Apps and Dashboards in dropdown: &lt;A href="https://answers.splunk.com/answers/639475/how-to-pass-a-dashboard-as-value-in-dropdown-of-an-1.html"&gt;https://answers.splunk.com/answers/639475/how-to-pass-a-dashboard-as-value-in-dropdown-of-an-1.html&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Wed, 27 Jun 2018 06:39:08 GMT</pubDate>
    <dc:creator>niketn</dc:creator>
    <dc:date>2018-06-27T06:39:08Z</dc:date>
    <item>
      <title>Getting Duplicate message when doing search for User ID (title)</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Getting-Duplicate-message-when-doing-search-for-User-ID-title/m-p/410320#M168679</link>
      <description>&lt;P&gt;This is the search I used:&lt;BR /&gt;
|rest /services/authentication/users splunk_server=local &lt;BR /&gt;
  |fields title&lt;BR /&gt;
  |rename title as user&lt;BR /&gt;
  |table user | sort user | dedup user&lt;/P&gt;

&lt;P&gt;I wanted to get the user Id and then use that in another search that is my panel in a dashboard:&lt;BR /&gt;
| rest /services/authentication/users splunk_server=local &lt;BR /&gt;
 | fields roles title realname &lt;BR /&gt;
 | rename title as username&lt;/P&gt;

&lt;P&gt;When I create the drop down and then key in the first search above, it keeps giving me duplicate values and no listing comes in.  Yet when I run it by itself in a search, it brings back what I need and doesn't give me the duplicate entries message.  I wanted to use the results of this search to plug into the 2nd search.&lt;/P&gt;</description>
      <pubDate>Tue, 26 Jun 2018 17:54:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Getting-Duplicate-message-when-doing-search-for-User-ID-title/m-p/410320#M168679</guid>
      <dc:creator>nls7010</dc:creator>
      <dc:date>2018-06-26T17:54:30Z</dc:date>
    </item>
    <item>
      <title>Re: Getting Duplicate message when doing search for User ID (title)</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Getting-Duplicate-message-when-doing-search-for-User-ID-title/m-p/410321#M168680</link>
      <description>&lt;P&gt;Hi @nls7010 ,&lt;/P&gt;

&lt;P&gt;It might not be the duplicate field but "fields for value" and "field for label" of your dropdown. Make sure that you have the same field name (her user) in  "fields for value" and "field for label" or rename them accordingly&lt;/P&gt;</description>
      <pubDate>Wed, 27 Jun 2018 02:49:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Getting-Duplicate-message-when-doing-search-for-User-ID-title/m-p/410321#M168680</guid>
      <dc:creator>renjith_nair</dc:creator>
      <dc:date>2018-06-27T02:49:24Z</dc:date>
    </item>
    <item>
      <title>Re: Getting Duplicate message when doing search for User ID (title)</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Getting-Duplicate-message-when-doing-search-for-User-ID-title/m-p/410322#M168681</link>
      <description>&lt;P&gt;@nls7010 can you share the Simple XML code for Dropdown which is throwing Duplicate Values error? (Use the &lt;CODE&gt;code button i.e. 101010&lt;/CODE&gt; or &lt;CODE&gt;Ctrl + K&lt;/CODE&gt; while posting code so that special characters do not escape.&lt;/P&gt;

&lt;P&gt;Also better way to run the same query would be as follows:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| rest /services/authentication/users splunk_server=local 
| fields title 
| dedup title 
| rename title as user 
| sort user
| table user
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;For reference, following is a previous run anywhere example code of mine which would get the logged in User's Role and then show Apps and Dashboards in dropdown: &lt;A href="https://answers.splunk.com/answers/639475/how-to-pass-a-dashboard-as-value-in-dropdown-of-an-1.html"&gt;https://answers.splunk.com/answers/639475/how-to-pass-a-dashboard-as-value-in-dropdown-of-an-1.html&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 27 Jun 2018 06:39:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Getting-Duplicate-message-when-doing-search-for-User-ID-title/m-p/410322#M168681</guid>
      <dc:creator>niketn</dc:creator>
      <dc:date>2018-06-27T06:39:08Z</dc:date>
    </item>
  </channel>
</rss>

