<?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: How to remove entry from being used 2x in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/How-to-remove-entry-from-being-used-2x/m-p/245527#M56173</link>
    <description>a example of data output &lt;BR /&gt;Id      Number  min_time1.         max_time1.       &lt;BR /&gt;1a.     123.          12/14/15 15:18.  12/14/15 15:25 &lt;BR /&gt;number min_time2.                    max time2. &lt;BR /&gt;456.          12/14/15 15:18.    12/14/15 15:34&lt;BR /&gt;that's is perfect but when I have a 3rd or 4th machine &lt;BR /&gt;I get this&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Id      Number  min_time1.         max_time1.       &lt;BR /&gt;1a.     123.          12/14/15 15:18.  12/14/15 15:25 &lt;BR /&gt;number min_time2.                    max time2. &lt;BR /&gt;300         12/14/15 15:02.    12/14/15 15:37&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;which duplicates 123  if 300 could be group with first example that be perfect</description>
    <pubDate>Fri, 22 Jan 2016 19:39:29 GMT</pubDate>
    <dc:creator>BETO</dc:creator>
    <dc:date>2016-01-22T19:39:29Z</dc:date>
    <item>
      <title>How to remove entry from being used 2x</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-remove-entry-from-being-used-2x/m-p/245494#M56167</link>
      <description>Hi after getting  the min an max with your help I need to see if machine on the same id were down at the same time I have a macro that does  that it looks like this&lt;BR /&gt;&lt;BR /&gt;% macro r (×,n);&amp;amp;x. As &amp;amp;x.&amp;amp;n. &amp;amp;mend;&lt;BR /&gt;proc sql;Create table want as select &lt;BR /&gt;a.id ,a.date , a.%r (number, 1),a.%r (min_time,1),a.%r (max_time,1),a.%r (dur_time,1),&lt;BR /&gt;B.id ,a.date , a.%r (number, 2),b.%r (min_time,3),b.%r (max_time,2),b.%r (dur_time,3)&lt;BR /&gt;from fix as a inner join fix as b on a.Id=b.id&lt;BR /&gt;where  (a.max_time gt b.min_time)&lt;BR /&gt;And &lt;BR /&gt;a.max_time LT b.max_time&lt;BR /&gt;)&lt;BR /&gt;Or ( a.max_time eq b.max_time&lt;BR /&gt;And &lt;BR /&gt;input (substr(a . number, 3,4)4.) LT input (substr( b.number,3,4.)&lt;BR /&gt;);&lt;BR /&gt;Run;&lt;BR /&gt;&lt;BR /&gt;What I get is if there are only 2 machines that overlap between there min an max time it works great ...but if there were 3 or 4 machined brought down it combined machine 1 with 2nd machine than in 2nd row it adds machine 1 to machine 3 I would like if machine 3 or 4 were all part of the first 2... I wonder if it's because I'm only refer a.b. I should c and d as well ? Thanks for help&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Fri, 22 Jan 2016 16:52:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-remove-entry-from-being-used-2x/m-p/245494#M56167</guid>
      <dc:creator>BETO</dc:creator>
      <dc:date>2016-01-22T16:52:22Z</dc:date>
    </item>
    <item>
      <title>Re: How to remove entry from being used 2x</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-remove-entry-from-being-used-2x/m-p/245527#M56173</link>
      <description>a example of data output &lt;BR /&gt;Id      Number  min_time1.         max_time1.       &lt;BR /&gt;1a.     123.          12/14/15 15:18.  12/14/15 15:25 &lt;BR /&gt;number min_time2.                    max time2. &lt;BR /&gt;456.          12/14/15 15:18.    12/14/15 15:34&lt;BR /&gt;that's is perfect but when I have a 3rd or 4th machine &lt;BR /&gt;I get this&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Id      Number  min_time1.         max_time1.       &lt;BR /&gt;1a.     123.          12/14/15 15:18.  12/14/15 15:25 &lt;BR /&gt;number min_time2.                    max time2. &lt;BR /&gt;300         12/14/15 15:02.    12/14/15 15:37&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;which duplicates 123  if 300 could be group with first example that be perfect</description>
      <pubDate>Fri, 22 Jan 2016 19:39:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-remove-entry-from-being-used-2x/m-p/245527#M56173</guid>
      <dc:creator>BETO</dc:creator>
      <dc:date>2016-01-22T19:39:29Z</dc:date>
    </item>
    <item>
      <title>Re: How to remove entry from being used 2x</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-remove-entry-from-being-used-2x/m-p/245596#M56178</link>
      <description>Post an example that breaks your code. Also please post a working code sample. Your code above would result in syntax errors.</description>
      <pubDate>Sat, 23 Jan 2016 03:52:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-remove-entry-from-being-used-2x/m-p/245596#M56178</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-01-23T03:52:21Z</dc:date>
    </item>
    <item>
      <title>Re: How to remove entry from being used 2x</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-remove-entry-from-being-used-2x/m-p/245718#M56181</link>
      <description>Hi reeza works when it compares one machine to another machine the issue is when there 3 machines it compares the 1st 2 than it inserts another row where it compares the 1st one again an the 3rd instead of adding the 3rd to the 1st two....I need it to look like this&lt;BR /&gt;1st.    And 2nd.   An 3rd if the dt. Overlaps ...not &lt;BR /&gt;1st.  And 2nd &lt;BR /&gt;1st.   And. 3rd ....&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;If I can add something that keeps the date time field one time and doesn't reuse it since it was used already ....hope that helps thanks for your assistance</description>
      <pubDate>Sun, 24 Jan 2016 19:13:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-remove-entry-from-being-used-2x/m-p/245718#M56181</guid>
      <dc:creator>BETO</dc:creator>
      <dc:date>2016-01-24T19:13:40Z</dc:date>
    </item>
    <item>
      <title>Re: How to remove entry from being used 2x</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-remove-entry-from-being-used-2x/m-p/246427#M56238</link>
      <description>Thanks Reeza</description>
      <pubDate>Wed, 27 Jan 2016 19:30:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-remove-entry-from-being-used-2x/m-p/246427#M56238</guid>
      <dc:creator>BETO</dc:creator>
      <dc:date>2016-01-27T19:30:28Z</dc:date>
    </item>
  </channel>
</rss>

