<?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: Problem of duplicate values in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331648#M61449</link>
    <description>&lt;P&gt;It's work,thank you &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 16 Apr 2018 07:51:56 GMT</pubDate>
    <dc:creator>taha13</dc:creator>
    <dc:date>2018-04-16T07:51:56Z</dc:date>
    <item>
      <title>Problem of duplicate values</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331642#M61443</link>
      <description>&lt;P&gt;Hello ,&lt;/P&gt;

&lt;P&gt;I have a question (or a problem) about my code:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;|loadjob savedsearch="a468413:ied:req_test2"
|eval time = strftime(_time,"%m/%d/%Y %I:%M %p")
|eval D1=if(MESSAGE="Connexion genesys OK + agent joint",strptime(time, "%m/%d/%Y %I:%M %p") ,NULL)
|eval D2=if(MESSAGE="Proposition du questionnaire de satisfaction client",strptime(time, "%m/%d/%Y %I:%M %p") ,NULL)
|eval diff=D2-D1
|where chatId="0007SaDCMCP301EX" AND (match(MESSAGE,"(\s|^)Replique(\s|$)") OR match(MESSAGE,"(\s|^)replique(\s|$)") OR MESSAGE="Proposition du questionnaire de satisfaction client" OR MESSAGE="Connexion genesys OK + agent joint") AND MESSAGE!="Le chat va etre cloture car le timeout de non replique client et conseiller a ete atteint"
|table _time,chatId,D1,D2
|sort _time asc
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The reslt that i want,is to have a table with one line with colums (chatId,D1,D2 AND diff),so here i have two problems,i have three D1(i want to take just the fist one),the second problem is that i have a lot of lines of one chatID&lt;/P&gt;

&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="alt text"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/4757i1D960BAD0DD6C77C/image-size/large?v=v2&amp;amp;px=999" role="button" title="alt text" alt="alt text" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 11 Apr 2018 09:01:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331642#M61443</guid>
      <dc:creator>taha13</dc:creator>
      <dc:date>2018-04-11T09:01:51Z</dc:date>
    </item>
    <item>
      <title>Re: Problem of duplicate values</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331643#M61444</link>
      <description>&lt;P&gt;@taha13, can you try the following and confirm:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; |loadjob savedsearch="a468413:ied:req_test2"
 |eval time = strftime(_time,"%m/%d/%Y %I:%M %p")
 |eval D1=if(MESSAGE="Connexion genesys OK + agent joint",strptime(time, "%m/%d/%Y %I:%M %p") ,NULL)
 |eval D2=if(MESSAGE="Proposition du questionnaire de satisfaction client",strptime(time, "%m/%d/%Y %I:%M %p") ,NULL)
 |eval diff=D2-D1
 |where chatId="0007SaDCMCP301EX" AND (match(MESSAGE,"(\s|^)Replique(\s|$)") OR match(MESSAGE,"(\s|^)replique(\s|$)") OR MESSAGE="Proposition du questionnaire de satisfaction client" OR MESSAGE="Connexion genesys OK + agent joint") AND MESSAGE!="Le chat va etre cloture car le timeout de non replique client et conseiller a ete atteint"
| sort _time asc
| dedup chatId D1 D2
| search D1=* OR D2=*
| table _time chatId D1 D2
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 11 Apr 2018 13:48:13 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331643#M61444</guid>
      <dc:creator>niketn</dc:creator>
      <dc:date>2018-04-11T13:48:13Z</dc:date>
    </item>
    <item>
      <title>Re: Problem of duplicate values</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331644#M61445</link>
      <description>&lt;P&gt;No result found&lt;/P&gt;</description>
      <pubDate>Wed, 11 Apr 2018 15:04:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331644#M61445</guid>
      <dc:creator>taha13</dc:creator>
      <dc:date>2018-04-11T15:04:01Z</dc:date>
    </item>
    <item>
      <title>Re: Problem of duplicate values</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331645#M61446</link>
      <description>&lt;P&gt;Try the following run anywhere search:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| makeresults
| eval chatId="004khjkdhsd76786",D1="1520048834.000"
| append 
    [| makeresults
| eval chatId="004khjkdhsd76786"]
| append 
    [| makeresults
| eval chatId="004khjkdhsd76786"]
| append 
    [| makeresults
| eval chatId="004khjkdhsd76786",D2="1400050002.000"]
| sort - _time asc
| fillnull value=0 D1,D2
| dedup chatId D1 D2
| search NOT(D1=0 AND D2=0)
| table _time chatId D1 D2
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 11 Apr 2018 15:31:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331645#M61446</guid>
      <dc:creator>niketn</dc:creator>
      <dc:date>2018-04-11T15:31:59Z</dc:date>
    </item>
    <item>
      <title>Re: Problem of duplicate values</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331646#M61447</link>
      <description>&lt;P&gt;can I write the formula instead of the values?&lt;/P&gt;</description>
      <pubDate>Fri, 13 Apr 2018 08:37:19 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331646#M61447</guid>
      <dc:creator>taha13</dc:creator>
      <dc:date>2018-04-13T08:37:19Z</dc:date>
    </item>
    <item>
      <title>Re: Problem of duplicate values</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331647#M61448</link>
      <description>&lt;P&gt;@taha13, what do you mean by formula? In the above run anywhere example you need to replace commands from &lt;CODE&gt;|makeresults&lt;/CODE&gt; to &lt;CODE&gt;|eval chartId&lt;/CODE&gt; with your current search.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;  |loadjob savedsearch="a468413:ied:req_test2"
  |eval time = strftime(_time,"%m/%d/%Y %I:%M %p")
  |eval D1=if(MESSAGE="Connexion genesys OK + agent joint",strptime(time, "%m/%d/%Y %I:%M %p") ,NULL)
  |eval D2=if(MESSAGE="Proposition du questionnaire de satisfaction client",strptime(time, "%m/%d/%Y %I:%M %p") ,NULL)
  |eval diff=D2-D1
  |where chatId="0007SaDCMCP301EX" AND (match(MESSAGE,"(\s|^)Replique(\s|$)") OR match(MESSAGE,"(\s|^)replique(\s|$)") OR MESSAGE="Proposition du questionnaire de satisfaction client" OR MESSAGE="Connexion genesys OK + agent joint") AND MESSAGE!="Le chat va etre cloture car le timeout de non replique client et conseiller a ete atteint"
 | sort - _time asc
 | fillnull value=0 D1,D2
 | dedup chatId D1 D2
 | search NOT(D1=0 AND D2=0)
 | table _time chatId D1 D2
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 13 Apr 2018 16:26:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331647#M61448</guid>
      <dc:creator>niketn</dc:creator>
      <dc:date>2018-04-13T16:26:49Z</dc:date>
    </item>
    <item>
      <title>Re: Problem of duplicate values</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331648#M61449</link>
      <description>&lt;P&gt;It's work,thank you &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 16 Apr 2018 07:51:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331648#M61449</guid>
      <dc:creator>taha13</dc:creator>
      <dc:date>2018-04-16T07:51:56Z</dc:date>
    </item>
    <item>
      <title>Re: Problem of duplicate values</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331649#M61450</link>
      <description>&lt;P&gt;Glad it worked, do up-vote the comment/s that helped &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 16 Apr 2018 08:28:13 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/Problem-of-duplicate-values/m-p/331649#M61450</guid>
      <dc:creator>niketn</dc:creator>
      <dc:date>2018-04-16T08:28:13Z</dc:date>
    </item>
  </channel>
</rss>

