<?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: SAS OLAP - How do I delete some data in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/415854#M280083</link>
    <description>&lt;P&gt;Yes, Pretty much.&lt;/P&gt;
&lt;P&gt;You can define your ROLAP aggregates in the Cube as your underlying Oracle Materialized Views. Depending on your Dimensions, Hierarchies and Drill-paths, you may be able to create and store SAS MOLAP aggregates in your Cube for data that doesn't intersect with Volatile/Changing data over time.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;BTW, Keep in mind, ROLAP aggregates does not have to be Database Tables/Views! They can be based on pr-aggregated SAS data sets. So if you have an ETL process that would extract data from Oracle and rebuild/update your underlying SAS Aggregates via Proc Summary/Means. You may not get the same performance speed if you don't store these per-aggregates in SPDE format, like how the OLAP Cube does behind the scenes.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You multiple options to consider and evaluate, an the end you have to choose what makes most sense to you and your organization.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Ahmed&lt;/P&gt;</description>
    <pubDate>Thu, 23 Nov 2017 15:44:00 GMT</pubDate>
    <dc:creator>AhmedAl_Attar</dc:creator>
    <dc:date>2017-11-23T15:44:00Z</dc:date>
    <item>
      <title>SAS OLAP - How do I delete some data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/414834#M280073</link>
      <description>&lt;P&gt;HI,&lt;/P&gt;&lt;P&gt;I have a huge cube (10 years of monthly data) that updates every month with the UPDATE_INPLACE option.&lt;/P&gt;&lt;P&gt;The cube is built on a view, that takes more place than the temporary library on the server can hold (when select * is executed )&lt;/P&gt;&lt;P&gt;and it can't be reloaded at once.&lt;/P&gt;&lt;P&gt;Let's say you have a change in the underlying data and have to reload one month. How do you do it ?&lt;/P&gt;&lt;P&gt;I can't (easily) rerun the cube. Additional&amp;nbsp;UPDATE_INPLACE run doubles the data&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;My idea would be to delete a month of data and reload it, nut I can't find the right option... any ideas?&amp;nbsp;&lt;/P&gt;&lt;P&gt;(SAS 9.3, DI 4.6, Proc OLAP )&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 20 Nov 2017 13:53:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/414834#M280073</guid>
      <dc:creator>lenats</dc:creator>
      <dc:date>2017-11-20T13:53:06Z</dc:date>
    </item>
    <item>
      <title>Re: SAS OLAP - How do I delete some data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/414839#M280074</link>
      <description>&lt;P&gt;Have you tried run a simple copy of the view to a sas dataset,&lt;/P&gt;
&lt;P&gt;either using proc copy or just:&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp;data new;&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; set have;&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp;run;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;what issues do you have to run such a code?&lt;/P&gt;</description>
      <pubDate>Mon, 20 Nov 2017 14:02:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/414839#M280074</guid>
      <dc:creator>Shmuel</dc:creator>
      <dc:date>2017-11-20T14:02:27Z</dc:date>
    </item>
    <item>
      <title>Re: SAS OLAP - How do I delete some data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/414841#M280075</link>
      <description>&lt;P&gt;The view contains a cartesian join tracking the customers' movement through the categories. one "slice" &amp;nbsp;= 500 mb, and we have 10 years of data . I don't want to use that much disk space&lt;/P&gt;&lt;P&gt;we used this design once, but moved to oracle view + bitmap indices instead.&lt;/P&gt;</description>
      <pubDate>Mon, 20 Nov 2017 14:06:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/414841#M280075</guid>
      <dc:creator>lenats</dc:creator>
      <dc:date>2017-11-20T14:06:31Z</dc:date>
    </item>
    <item>
      <title>Re: SAS OLAP - How do I delete some data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/414844#M280076</link>
      <description>&lt;P&gt;Something is not clear to me:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You said "&lt;STRONG&gt;&lt;SPAN&gt;Additional&amp;nbsp;UPDATE_INPLACE run doubles the data".&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You have a view of 10 years. Your update is of one month only.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Then what do you mean that it&amp;nbsp;&lt;U&gt;&lt;STRONG&gt;doubles&lt;/STRONG&gt; &lt;/U&gt;the data ?&lt;/P&gt;
&lt;P&gt;and if update is &lt;U&gt;&lt;STRONG&gt;INPLACE&lt;/STRONG&gt; &lt;/U&gt;why should it double the data ?&lt;/P&gt;</description>
      <pubDate>Mon, 20 Nov 2017 14:15:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/414844#M280076</guid>
      <dc:creator>Shmuel</dc:creator>
      <dc:date>2017-11-20T14:15:56Z</dc:date>
    </item>
    <item>
      <title>Re: SAS OLAP - How do I delete some data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/414854#M280077</link>
      <description>The cube is updated from a temporary table. The whole view is only used for&lt;BR /&gt;the drill through and rerun (initialize) purposes&lt;BR /&gt;</description>
      <pubDate>Mon, 20 Nov 2017 14:51:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/414854#M280077</guid>
      <dc:creator>lenats</dc:creator>
      <dc:date>2017-11-20T14:51:43Z</dc:date>
    </item>
    <item>
      <title>Re: SAS OLAP - How do I delete some data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/414860#M280078</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;There are few factors about OLAP cubes you'll have to consider here, specially when it comes to updating historical data elements stored in the cube.&lt;/P&gt;
&lt;P&gt;1. Hierarchies involving your Time Dimension elements/variables&lt;/P&gt;
&lt;P&gt;2. Stored Aggregations that directly/explicitly contains your monthly data (Month level/Quarter level/Yearly level)&lt;/P&gt;
&lt;P&gt;3. Stored Aggregations that indirectly/implicitly contains your monthly data (Year over Year differences, Annual Total by other dimension)&lt;/P&gt;
&lt;P&gt;4. Custom Calculated Members / MDX formulas&lt;/P&gt;
&lt;P&gt;5. Custom Sets&lt;/P&gt;
&lt;P&gt;6. ?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;When you start looking at how your monthly data is consumed inside your Cube, you'll realize, sometimes the best way to ensure your data updates get propagated&amp;nbsp;correctly, is to rebuild the entire cube!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you had the OLAP Cube built/constructed using per-aggregated tables (&lt;A href="http://documentation.sas.com/?docsetId=olapug&amp;amp;docsetTarget=p0byq5gwebsmbwn1hxksxq6a7vmd.htm&amp;amp;docsetVersion=9.4&amp;amp;locale=en" target="_self"&gt;ROLAP Aggregation Storage&lt;/A&gt;), then you can go ahead, and update each and every involving aggregation table in order to update the OLAP Reports &amp;amp; results.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;BTW, this is how you can use Proc SQL to access a SAS OLAP Cube,&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sql;
connect to olap (host=localhost port=5451 user=user pass=pass);
         select * from connection to olap (
              "select [A].[All A].[M].[Adam's] on Rows,
                 crossjoin([Measures].defaultMember, [B].defaultMember)
                 on Columns
                   from [QuoteTest]"
       );
disconnect from olap;
quit;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Just my 2 cents,&lt;/P&gt;
&lt;P&gt;Hope it helps,&lt;/P&gt;
&lt;P&gt;Ahmed&lt;/P&gt;</description>
      <pubDate>Mon, 20 Nov 2017 15:14:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/414860#M280078</guid>
      <dc:creator>AhmedAl_Attar</dc:creator>
      <dc:date>2017-11-20T15:14:12Z</dc:date>
    </item>
    <item>
      <title>Re: SAS OLAP - How do I delete some data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/415047#M280079</link>
      <description>&lt;P&gt;Let's say i've already loaded my september data, and the cube shows that i have total&amp;nbsp;5 million customers&lt;/P&gt;&lt;P&gt;If I load it again with update_inplace &amp;nbsp;the cube shows me 10 million customers&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The oracle tables underlying the view are partitioned, therefore I can easily load one month.&lt;/P&gt;&lt;P&gt;They have bitmap indices too, so that the drill through works really fast (the hierarchies correspond to the indices)&lt;/P&gt;&lt;P&gt;what I can't do is to perform a select * from the view without any where statements, the oracle's temp space can't hold it, and the SAS work space &amp;nbsp;can't hold it either.&lt;/P&gt;</description>
      <pubDate>Tue, 21 Nov 2017 07:17:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/415047#M280079</guid>
      <dc:creator>lenats</dc:creator>
      <dc:date>2017-11-21T07:17:07Z</dc:date>
    </item>
    <item>
      <title>Re: SAS OLAP - How do I delete some data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/415049#M280080</link>
      <description>&lt;P&gt;The cube is not that complicated. Nway aggregation, shallow time dim (only months) the most complicated hierarchy&amp;nbsp;is 4 level internal hierarchy tree, simple calculated members (ratios etc) .&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Most of the work is done by the ETL beforehand, creating the "slices" ( each slice contains a customer,base month, new month, the data contains his movement between hierarchies' members , i.e. John was premium in 03/2014, nowdays not-so-premium.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The cube shows movement totals, i.e. comparing mar 2014 to 2017 10 clients moved to premium, 15 clients moved from premium to ordinary, 10 clients are new, 20 left, 150 stayed in premium,1000 stayed in ordinary class&lt;/P&gt;</description>
      <pubDate>Tue, 21 Nov 2017 07:31:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/415049#M280080</guid>
      <dc:creator>lenats</dc:creator>
      <dc:date>2017-11-21T07:31:20Z</dc:date>
    </item>
    <item>
      <title>Re: SAS OLAP - How do I delete some data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/415523#M280081</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;I think it's fare to say, the Update feature of the SAS OLAP Cubes are Incremental Updates, rather than Historical Updates!&lt;/P&gt;
&lt;P&gt;&lt;A title="What’s New in SAS ®  OLAP Cube Studio 4.2 " href="http://support.sas.com/resources/papers/sgf2008/cubestudio42.pdf" target="_self"&gt;- What’s New in SAS ® OLAP Cube Studio 4.2 &lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Therefore I would encourage you to review the following links to get an idea of your alternative approaches and design decisions&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;- &lt;A title="SAS ®  OLAP Cube Tuning and Query Performance Optimization" href="http://support.sas.com/resources/papers/proceedings12/026-2012.pdf" target="_self"&gt;SAS ® OLAP Cube Tuning and Query Performance Optimization&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;- &lt;A title="Manipulating OLAP Cubes: Advanced Techniques for SAS ®  Programmers " href="http://support.sas.com/resources/papers/proceedings09/042-2009.pdf" target="_self"&gt;Manipulating OLAP Cubes: Advanced Techniques for SAS ® Programmers &lt;/A&gt;&lt;/P&gt;
&lt;P&gt;- &lt;A title="Escape from Big Data Restrictions by Leveraging  Advanced OLAP Cube Techniques" href="http://support.sas.com/resources/papers/proceedings13/047-2013.pdf" target="_self"&gt;Escape from Big Data Restrictions by Leveraging Advanced OLAP Cube Techniques&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;- &lt;A title="Using SAS ®  OLAP Server for a ROLAP Scenario " href="https://support.sas.com/resources/papers/proceedings09/103-2009.pdf" target="_self"&gt;Using SAS ® OLAP Server for a ROLAP Scenario &lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;- Utilizing Oracle Materialized Views as underlying aggregates&lt;/P&gt;
&lt;P&gt;&lt;A title="Basic Materialized Views" href="https://docs.oracle.com/cd/E11882_01/server.112/e25554/basicmv.htm#DWHSG008" target="_self"&gt;Basic Materialized Views&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A title="CREATE MATERIALIZED VIEW" href="https://docs.oracle.com/cd/B19306_01/server.102/b14200/statements_6002.htm" target="_self"&gt;CREATE MATERIALIZED VIEW&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A title="OLAP Expression Syntax Reference" href="https://docs.oracle.com/cd/E11882_01/olap.112/e23381/toc.htm" target="_self"&gt;OLAP Expression Syntax Reference&lt;/A&gt; -- &lt;A title="OLAP Functions" href="https://docs.oracle.com/cd/E11882_01/olap.112/e23381/olap_functions.htm#OLAXS169" target="_self"&gt;OLAP Functions&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In Summary, I think you would be better served by utilizing Oracle Materialized Views &amp;amp; Aggregates, to handle underlying Historical Data Updates and Drill-Through queries. And for Client movement totals you can either per-calculate them in the your Materialized Views, using Oracle's OLAP Functions or using MDX within your Proc OLAP Statements to define Calculated Members.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In theory, this design would allow you to:&lt;/P&gt;
&lt;P&gt;- Handle all future Historical data updates automatically by Oracle - Faster availability for Reporting&lt;/P&gt;
&lt;P&gt;- Handle all future Incremental data Updates automatically by Oracle - Faster availability for Reporting&lt;/P&gt;
&lt;P&gt;- Allow for other tools to utilize the Oracle Materialized Views&lt;/P&gt;
&lt;P&gt;- Reduce data duplication, as the data would only reside in Oracle, rather than storing additional Aggregates in SAS OLAP Cube(s)&lt;/P&gt;
&lt;P&gt;- Reduce/Eliminate some of the existing ETL jobs and transformations&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Ahmed&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 22 Nov 2017 14:38:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/415523#M280081</guid>
      <dc:creator>AhmedAl_Attar</dc:creator>
      <dc:date>2017-11-22T14:38:56Z</dc:date>
    </item>
    <item>
      <title>Re: SAS OLAP - How do I delete some data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/415768#M280082</link>
      <description>&lt;P&gt;Let me see if I&amp;nbsp;understand you&lt;/P&gt;&lt;P&gt;the idea is to build the oracle view for the drill through purposes , and to add a materialized view that sums the data and to build the cube on the materialized view without the nway aggregation ?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 23 Nov 2017 08:21:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/415768#M280082</guid>
      <dc:creator>lenats</dc:creator>
      <dc:date>2017-11-23T08:21:41Z</dc:date>
    </item>
    <item>
      <title>Re: SAS OLAP - How do I delete some data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/415854#M280083</link>
      <description>&lt;P&gt;Yes, Pretty much.&lt;/P&gt;
&lt;P&gt;You can define your ROLAP aggregates in the Cube as your underlying Oracle Materialized Views. Depending on your Dimensions, Hierarchies and Drill-paths, you may be able to create and store SAS MOLAP aggregates in your Cube for data that doesn't intersect with Volatile/Changing data over time.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;BTW, Keep in mind, ROLAP aggregates does not have to be Database Tables/Views! They can be based on pr-aggregated SAS data sets. So if you have an ETL process that would extract data from Oracle and rebuild/update your underlying SAS Aggregates via Proc Summary/Means. You may not get the same performance speed if you don't store these per-aggregates in SPDE format, like how the OLAP Cube does behind the scenes.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You multiple options to consider and evaluate, an the end you have to choose what makes most sense to you and your organization.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Ahmed&lt;/P&gt;</description>
      <pubDate>Thu, 23 Nov 2017 15:44:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/415854#M280083</guid>
      <dc:creator>AhmedAl_Attar</dc:creator>
      <dc:date>2017-11-23T15:44:00Z</dc:date>
    </item>
    <item>
      <title>Re: SAS OLAP - How do I delete some data</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/415875#M280084</link>
      <description>Thank you for the ideas! I'll try it.&lt;BR /&gt;</description>
      <pubDate>Thu, 23 Nov 2017 17:23:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-OLAP-How-do-I-delete-some-data/m-p/415875#M280084</guid>
      <dc:creator>lenats</dc:creator>
      <dc:date>2017-11-23T17:23:43Z</dc:date>
    </item>
  </channel>
</rss>

