<?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: In which scenario would you not use an index even though using an index would increase efficienc in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251145#M268755</link>
    <description>&lt;P&gt;Yes, even i'm trying to imagine a scenario. Maybe what you say could happen.&lt;/P&gt;</description>
    <pubDate>Fri, 19 Feb 2016 14:41:12 GMT</pubDate>
    <dc:creator>krzy32</dc:creator>
    <dc:date>2016-02-19T14:41:12Z</dc:date>
    <item>
      <title>In which scenario would you not use an index even though using an index would increase efficiency?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251037#M268748</link>
      <description>&lt;P&gt;SAS 9.4&lt;/P&gt;&lt;P&gt;I am learning Advanced SAS currently. The idxwhere=no options can be used to specify not to use an index. In what possible scenario would you tell SAS not to use indexes ? SAS predicts whether to use an index or not. If the program fulfils criteria for not using indexes, it's obvious even SAS knows those scenarios. Why would you decrease efficiency by telling SAS not to use an index?&lt;/P&gt;</description>
      <pubDate>Fri, 19 Feb 2016 07:09:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251037#M268748</guid>
      <dc:creator>krzy32</dc:creator>
      <dc:date>2016-02-19T07:09:37Z</dc:date>
    </item>
    <item>
      <title>Re: In which scenario would you not use an index even though using an index would increase efficienc</title>
      <link>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251040#M268749</link>
      <description>&lt;P&gt;Remember that computers are dumb. This option comes into play when you prove to be more intelligent than the SAS optimization algorithm.&lt;/P&gt;</description>
      <pubDate>Fri, 19 Feb 2016 07:16:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251040#M268749</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2016-02-19T07:16:17Z</dc:date>
    </item>
    <item>
      <title>Re: In which scenario would you not use an index even though using an index would increase efficienc</title>
      <link>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251043#M268750</link>
      <description>&lt;P&gt;Yes but I cannot imagine any scenario in which I would need to explicitly tell SAS not to use indexes even though I risk decreasing efficiency but get same results as when index was used. Can you help me or have you come across any such scenario?&lt;/P&gt;</description>
      <pubDate>Fri, 19 Feb 2016 07:40:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251043#M268750</guid>
      <dc:creator>krzy32</dc:creator>
      <dc:date>2016-02-19T07:40:16Z</dc:date>
    </item>
    <item>
      <title>Re: In which scenario would you not use an index even though using an index would increase efficienc</title>
      <link>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251046#M268751</link>
      <description>&lt;P&gt;When you get most part of a table (like 70% 80%),not using index is faster than using index.&lt;/P&gt;</description>
      <pubDate>Fri, 19 Feb 2016 07:46:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251046#M268751</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2016-02-19T07:46:55Z</dc:date>
    </item>
    <item>
      <title>Re: In which scenario would you not use an index even though using an index would increase efficienc</title>
      <link>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251047#M268752</link>
      <description>&lt;P&gt;Agreed but SAS has an inbuilt algorithm that estimates output dataset. In the scenario you specified, had we not mentioned any index option, SAS would not have used indexing as about 70%-80% of dataset is being used.&lt;/P&gt;</description>
      <pubDate>Fri, 19 Feb 2016 07:50:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251047#M268752</guid>
      <dc:creator>krzy32</dc:creator>
      <dc:date>2016-02-19T07:50:14Z</dc:date>
    </item>
    <item>
      <title>Re: In which scenario would you not use an index even though using an index would increase efficienc</title>
      <link>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251082#M268753</link>
      <description>Yes there is an algorithm. But that can't foresee everything. So I guess that there is no straight answer. I'm thinking that in a real life example find the use of index inefficient and thenot turn that off explicitly for that query.&lt;BR /&gt;One situation I can imagine is the the index is heavily fragmented so that even if just 10% rows is returned, let's say that 50% of the data pages is read.</description>
      <pubDate>Fri, 19 Feb 2016 11:50:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251082#M268753</guid>
      <dc:creator>LinusH</dc:creator>
      <dc:date>2016-02-19T11:50:43Z</dc:date>
    </item>
    <item>
      <title>Re: In which scenario would you not use an index even though using an index would increase efficienc</title>
      <link>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251137#M268754</link>
      <description>&lt;P&gt;I don't know if this is a good example but I shows one scenario where turning off the index changes what you get back. &amp;nbsp;Notice that using the index the values are returned in INDEX order while not using it they are returned in OBS order. &amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;41         options msglevel=i;
42         data byage;
43            set class;
44            where age in(12 15);
INFO: Index Age selected for WHERE clause optimization.
45            run;

NOTE: There were 9 observations read from the data set WORK.CLASS.
      WHERE age in (12, 15);
NOTE: The data set WORK.BYAGE has 9 observations and 6 variables.
NOTE: DATA statement used (Total process time):
      real time           0.02 seconds
      cpu time            0.02 seconds
      

46         proc print;
47            run;

NOTE: There were 9 observations read from the data set WORK.BYAGE.
NOTE: PROCEDURE PRINT used (Total process time):
      real time           0.02 seconds
      cpu time            0.03 seconds
      

48         data byage;
49            set class(idxwhere=no);
50            where age in(12 15);
INFO: Data set option (IDXWHERE=NO) forced a sequential pass of the data rather than use of an index for where-clause processing.
51            run;

NOTE: There were 9 observations read from the data set WORK.CLASS.
      WHERE age in (12, 15);
NOTE: The data set WORK.BYAGE has 9 observations and 6 variables.
NOTE: DATA statement used (Total process time):
      real time           0.02 seconds
      cpu time            0.03 seconds&lt;/PRE&gt;
&lt;P&gt;&lt;IMG src="https://communities.sas.com/t5/image/serverpage/image-id/1957iB714863CE17BDB5A/image-size/original?v=mpbl-1&amp;amp;px=-1" border="0" alt="Capture.PNG" title="Capture.PNG" /&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 19 Feb 2016 14:33:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251137#M268754</guid>
      <dc:creator>data_null__</dc:creator>
      <dc:date>2016-02-19T14:33:48Z</dc:date>
    </item>
    <item>
      <title>Re: In which scenario would you not use an index even though using an index would increase efficienc</title>
      <link>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251145#M268755</link>
      <description>&lt;P&gt;Yes, even i'm trying to imagine a scenario. Maybe what you say could happen.&lt;/P&gt;</description>
      <pubDate>Fri, 19 Feb 2016 14:41:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251145#M268755</guid>
      <dc:creator>krzy32</dc:creator>
      <dc:date>2016-02-19T14:41:12Z</dc:date>
    </item>
    <item>
      <title>Re: In which scenario would you not use an index even though using an index would increase efficienc</title>
      <link>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251354#M268756</link>
      <description>&lt;P&gt;Thank you for your answer. Can you please post the log with the fullstimer option?&lt;/P&gt;</description>
      <pubDate>Sat, 20 Feb 2016 20:04:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/In-which-scenario-would-you-not-use-an-index-even-though-using/m-p/251354#M268756</guid>
      <dc:creator>krzy32</dc:creator>
      <dc:date>2016-02-20T20:04:40Z</dc:date>
    </item>
  </channel>
</rss>

