<?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: processing a variable number of programm blocs after one another in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/574023#M162114</link>
    <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/281554"&gt;@PierreYvesILY&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;thanks for your answer.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;1. The names of the variables with &amp;amp;Jahr11. and so forth are created exactly for the purpose of copying the results in separate columns in Excel afterwards.&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000ff"&gt;&lt;STRONG&gt;2. I have to calculate evolutions in % between both years, so I build yearly variables to do so : &amp;nbsp;(Var&amp;amp;Jahr11.- Var&amp;nbsp;&amp;amp;Jahr12.)=Delta&amp;nbsp;&amp;amp;Jahr11. in %&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000ff"&gt;&lt;STRONG&gt;If you can suggest a way to calculate the Delta with only one variable + an additional variable Jahr, I'd be pleased to use it.&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;It would simplify the code a LOT.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I don't understand what you mean by: proc summary and a data step with array code&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;thanks and have a nice day&lt;/P&gt;
&lt;P&gt;PY&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Would have to see some example INPUT data to see what is possible.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Proc summary (or means) will group data and do sums (or other statistics) into the same variable with less fuss than SQL.&lt;/P&gt;
&lt;PRE&gt;proc summary data=  Liste_teil_5 nway;
   class STUFE MARKTREGION_BT NL_BT NLBEZ_BT MBRBEZ_BT;
   var  ORB_Anzahl_Akt_&amp;amp;Jahr11.  ORB_TVOL_Akt_&amp;amp;Jahr11.
        ORB_Anzahl_Akt_&amp;amp;Jahr11.    /* continue with all the 
                                   variables that need sums*/
   ;
   output out =temp  sum= ;
run;&lt;/PRE&gt;
&lt;P&gt;If it happens that you need every single one of your variables that start with ORB to be summed the above could reduce the VAR statement to something like:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp; var ORB: ;&lt;/P&gt;
&lt;P&gt;as proc summary/ means can use variable lists.&lt;/P&gt;
&lt;PRE&gt;proc summary data=  Liste_teil_5 nway;
   class STUFE MARKTREGION_BT NL_BT NLBEZ_BT MBRBEZ_BT;
   var  ORB: ngs: ;  
   output out =temp  sum= ;
run;&lt;/PRE&gt;
&lt;P&gt;The above would sum ALL numeric variables whose names start with ORB and NGS and place the sum in a variable of the same name in the output set.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Then a data step similar to:&lt;/P&gt;
&lt;PRE&gt;data want;
   set temp;
   /* calculate the rates*/
   array n &amp;lt;list the numerator variables&amp;gt;;
   array d &amp;lt;list the denominator variables in corresponding order&amp;gt;;
   array r &amp;lt;list the results variables of the rate calculations&amp;gt;;
   /* this do loop */
   do i= 1 to dim(n);
      r[i] = n[i] / d[i];
   end;
   /* would replace all of these */
   ORB_Anzahl_VZK_&amp;amp;Jahr11. =  ORB_Anzahl_Akt_&amp;amp;Jahr11./Anzahl_VZK_&amp;amp;Jahr11.;

   format orb: NGS: commax17.;
run;
&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp; I wasn't about to copy out all of your variable names.&lt;/P&gt;
&lt;P&gt;The ability to use variable lists in data step code can make things much simpler. If you need to process columns that appear in order you can use a list with two dashes in an array definition (or the var statement in Proc Summary / means).&lt;/P&gt;
&lt;P&gt;Example: if the variables ABC ABD ABQ BDD BDE are adjacent and I want to process them in some way in that order I could use an array definition of : array v&amp;nbsp;&amp;nbsp; ABC -- BDE;&lt;/P&gt;
&lt;P&gt;Also not the variable list in the Format statement much simpler. Or if I had a lot of variables to assign a format I might be tempted to use Proc Datasets after the set is created to assign the format instead of having so many &lt;FONT face="Courier New"&gt;format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17. &lt;FONT color="#000000" face="arial,helvetica,sans-serif"&gt;&lt;FONT color="#333333" face="Helvetica"&gt;scattered through the code.&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 16 Jul 2019 21:55:08 GMT</pubDate>
    <dc:creator>ballardw</dc:creator>
    <dc:date>2019-07-16T21:55:08Z</dc:date>
    <item>
      <title>processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573459#M161902</link>
      <description>&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I use a long programm to download, process, and export data, on a monthly basis. I want to use this programm several times to cover several months, one after the other, and export a combined file gathering all monthly data.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For instance, I now have a result : month n / structure / data 1..x&lt;/P&gt;&lt;P&gt;Target is:&lt;/P&gt;&lt;P&gt;month n / structure / data 1..x&lt;/P&gt;&lt;P&gt;month n+1 / structure / data 1..x&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;month n+i / structure / data 1..x,&amp;nbsp;&amp;nbsp; i being the number of selected months.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How can I achieve this?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Jul 2019 10:27:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573459#M161902</guid>
      <dc:creator>PierreYvesILY</dc:creator>
      <dc:date>2019-07-15T10:27:24Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573460#M161903</link>
      <description>&lt;P&gt;Why would month N have to be processed before month N+1? Can't you just process all the months together and then export one file?&lt;/P&gt;</description>
      <pubDate>Mon, 15 Jul 2019 11:01:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573460#M161903</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2019-07-15T11:01:27Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573463#M161904</link>
      <description>&lt;P&gt;No, it would be a cumulative File as a result, which I already process also.&lt;/P&gt;&lt;P&gt;The program selects data for a certain time period, and then for each variable the data are summed, or other calculations take place.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The programm has 3 main blocs where the data downloaded form diffrent sources are processed this way. So, I have for each block to select the data of the 1st month, then process, then store the results. Afterwards, I want to do the same for the next month.&lt;/P&gt;&lt;P&gt;After all this, I need to merge all tables obtained and process the export.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My goal is to edit i monthly data stands for each structure of the company.&lt;/P&gt;&lt;P&gt;i.e: if i=6 months =&amp;gt; 6 lines, and each line having the result of each variable for each month.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm not familiar with SAS or programming, I first started to learn SAS programming in August last year.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for your help&lt;/P&gt;</description>
      <pubDate>Mon, 15 Jul 2019 11:17:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573463#M161904</guid>
      <dc:creator>PierreYvesILY</dc:creator>
      <dc:date>2019-07-15T11:17:03Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573465#M161905</link>
      <description>&lt;P&gt;Nothing you have said, if I am understanding you properly, makes it necessary to perform the step separaetly for each month. SAS has many ways to do one big analysis, BY MONTH, so you don't have the run the code many times; you run it once and let SAS break it up.&lt;/P&gt;</description>
      <pubDate>Mon, 15 Jul 2019 11:59:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573465#M161905</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2019-07-15T11:59:06Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573468#M161906</link>
      <description>&lt;P&gt;I've no idea how to do this with the data I have (month has to be added to the data), and break it correctly down afterwards.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For instance, I have this step, that has to be run for each month and for each level of the company structure (the levels are quoted in the group option below):&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;/* Aggregation und Quoten-Neu Berechnung für FIL */&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;proc&lt;/STRONG&gt;&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;sql&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;; &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;create&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;table&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; FIL2 &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;select&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; STUFE ,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;MARKTREGION_BT,&lt;/P&gt;&lt;P&gt;NL_BT,&lt;/P&gt;&lt;P&gt;NLBEZ_BT,&lt;/P&gt;&lt;P&gt;MBRBEZ_BT,&lt;/P&gt;&lt;P&gt;&lt;FONT color="#008000" face="Courier New" size="3"&gt;/* '' as FILHB_BT length=5, */&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;FILBEZ_BT length=&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;35&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;, &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_TVOL_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_TVOL_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.1&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_TVOL_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_TVOL_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_GEN_Quote_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;(&lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;case&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;when&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (sum(ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) = &lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;and&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;not&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;in&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;.&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;)) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;then&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;when&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (sum(ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) = &lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;.&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;and&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;not&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;in&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;.&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;)) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;then&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;else&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt; - (sum(ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;)))&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;end&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_FINO_QUOTE_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_NGV_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_NGV_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_NGV_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_TICKET_AVG_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.1&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_RSV_Anz_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; RSV_QUOTE_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Auszahlungsquote_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.2&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_RSV_Anz_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_RSV_Anz_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Akt_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_Akt_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_TVOL_Akt_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_TVOL_Akt_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_TVOL_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_TVOL_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Anzahl_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;, &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_NGV_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_NGV_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Auszahlungsquote_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;, &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.1&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Gruen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_GRUEN_Quote_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_TVOL_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_TVOL_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.1&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_TVOL_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_TVOL_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_GEN_Quote_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;(&lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;case&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;when&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (sum(ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) = &lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;and&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;not&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;in&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;.&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;)) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;then&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;when&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (sum(ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) = &lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;.&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;and&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;not&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;in&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;.&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;)) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;then&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;else&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt; - (sum(ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;)))&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;end&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_FINO_QUOTE_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_NGV_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_NGV_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_NGV_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_TICKET_AVG_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.1&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_RSV_Anz_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; RSV_QUOTE_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Auszahlungsquote_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.2&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_RSV_Anz_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_RSV_Anz_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Akt_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_Akt_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_TVOL_Akt_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_TVOL_Akt_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_TVOL_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_TVOL_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Anzahl_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;, &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_NGV_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_NGV_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Auszahlungsquote_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;, &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.1&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Gruen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_GRUEN_Quote_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;from&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; Liste_teil_5&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;group&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;by&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;STUFE,&lt;/P&gt;&lt;P&gt;MARKTREGION_BT,&lt;/P&gt;&lt;P&gt;NL_BT,&lt;/P&gt;&lt;P&gt;NLBEZ_BT,&lt;/P&gt;&lt;P&gt;MBRBEZ_BT,&lt;/P&gt;&lt;P&gt;FILBEZ_BT;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;quit&lt;/STRONG&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;in the next step, I take the next level:&lt;/P&gt;&lt;P&gt;/* Aggregation und Quoten-Neu Berechnung für MBR */&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;proc&lt;/STRONG&gt;&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;sql&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;; &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;create&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;table&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; MBR &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;select&lt;/FONT&gt; &lt;FONT color="#800080" face="Courier New" size="3"&gt;'MBR'&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; STUFE ,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;MARKTREGION_BT,&lt;/P&gt;&lt;P&gt;NL_BT,&lt;/P&gt;&lt;P&gt;NLBEZ_BT,&lt;/P&gt;&lt;P&gt;MBRBEZ_BT,&lt;/P&gt;&lt;P&gt;&lt;FONT color="#008000" face="Courier New" size="3"&gt;/* '' as FILHB_BT length=5, */&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;''&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; FILBEZ_BT length=&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;35&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;, &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_TVOL_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_TVOL_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.1&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_TVOL_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_TVOL_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_GEN_Quote_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;(&lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;case&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;when&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (sum(ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) = &lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;and&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;not&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;in&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;.&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;)) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;then&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;when&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (sum(ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) = &lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;.&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;and&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;not&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;in&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;.&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;)) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;then&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;else&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt; - (sum(ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;)))&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;end&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_FINO_QUOTE_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_NGV_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_NGV_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_NGV_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_TICKET_AVG_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.1&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_RSV_Anz_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; RSV_QUOTE_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Auszahlungsquote_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.2&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_RSV_Anz_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_RSV_Anz_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Akt_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_Akt_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_TVOL_Akt_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_TVOL_Akt_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_TVOL_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_TVOL_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Anzahl_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;, &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_NGV_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_NGV_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Auszahlungsquote_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;, &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.1&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Gruen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_GRUEN_Quote_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_TVOL_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_TVOL_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.1&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_TVOL_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_TVOL_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_GEN_Quote_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;(&lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;case&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;when&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (sum(ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) = &lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;and&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;not&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;in&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;.&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;)) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;then&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;when&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (sum(ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) = &lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;.&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;and&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;not&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;in&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;0&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;.&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;)) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;then&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;else&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; (&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;1&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt; - (sum(ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;)))&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;end&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_FINO_QUOTE_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_NGV_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_NGV_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_NGV_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_TICKET_AVG_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.1&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_RSV_Anz_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; RSV_QUOTE_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Auszahlungsquote_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.2&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_kein_Fino_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_RSV_Anz_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_RSV_Anz_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Akt_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_Akt_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_TVOL_Akt_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_TVOL_Akt_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_Anzahl_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_TVOL_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_TVOL_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Anzahl_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;, &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_NGV_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_NGV_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Gen_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Auszahlungsquote_Online_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;, &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(NGS_Anzahl_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; NGS_Anzahl_VZK_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.1&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;sum(ORB_Anzahl_Gruen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) / sum(ORB_Anzahl_Gen_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;) &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ORB_GRUEN_Quote_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr12.&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17.3&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;from&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; Liste_teil_5&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;group&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;by&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;STUFE,&lt;/P&gt;&lt;P&gt;MARKTREGION_BT,&lt;/P&gt;&lt;P&gt;NL_BT,&lt;/P&gt;&lt;P&gt;NLBEZ_BT,&lt;/P&gt;&lt;P&gt;MBRBEZ_BT;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;quit&lt;/STRONG&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;there is no month / time variable, as all data refer to a selected time period.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thus, I don't know how to do.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Jul 2019 12:13:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573468#M161906</guid>
      <dc:creator>PierreYvesILY</dc:creator>
      <dc:date>2019-07-15T12:13:42Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573469#M161907</link>
      <description>&lt;P&gt;What is the difference between the two different blocks of code you show?&lt;/P&gt;</description>
      <pubDate>Mon, 15 Jul 2019 12:17:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573469#M161907</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2019-07-15T12:17:12Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573477#M161909</link>
      <description>&lt;P&gt;hi Paige,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;the difference lies is the level FILBEZ_BT:&lt;/P&gt;&lt;P&gt;1. Block:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;select&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; STUFE ,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;MARKTREGION_BT,&lt;/P&gt;&lt;P&gt;NL_BT,&lt;/P&gt;&lt;P&gt;NLBEZ_BT,&lt;/P&gt;&lt;P&gt;MBRBEZ_BT,&lt;/P&gt;&lt;P&gt;&lt;FONT color="#008000" face="Courier New" size="3"&gt;/* '' as FILHB_BT length=5, */&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;FILBEZ_BT length=&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;35&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;, &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2nd Block:&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;select&lt;/FONT&gt; &lt;FONT color="#800080" face="Courier New" size="3"&gt;'MBR'&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; STUFE ,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;MARKTREGION_BT,&lt;/P&gt;&lt;P&gt;NL_BT,&lt;/P&gt;&lt;P&gt;NLBEZ_BT,&lt;/P&gt;&lt;P&gt;MBRBEZ_BT,&lt;/P&gt;&lt;P&gt;&lt;FONT color="#008000" face="Courier New" size="3"&gt;/* '' as FILHB_BT length=5, */&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;''&lt;/FONT&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;as&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; FILBEZ_BT length=&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;35&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;, &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;the 1st block calculates all values on the FILBEZ_BT level ; the second one on the MBRBEZ_BT level.&lt;/P&gt;&lt;P&gt;In a further step, the 2 tables are pu together, so that both levels are present in the final data table that will be exported.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This programm generates a reporting that is used by the final users in excel and they want to select different levels of the company structure.&lt;/P&gt;</description>
      <pubDate>Mon, 15 Jul 2019 12:55:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573477#M161909</guid>
      <dc:creator>PierreYvesILY</dc:creator>
      <dc:date>2019-07-15T12:55:57Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573479#M161910</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/281554"&gt;@PierreYvesILY&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;hi Paige,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;the 1st block calculates all values on the FILBEZ_BT level ; the second one on the MBRBEZ_BT level.&lt;/P&gt;
&lt;P&gt;In a further step, the 2 tables are pu together, so that both levels are present in the final data table that will be exported.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;I don't know what these two levels are. I also don't see how this relates to your original problem where you wanted to run the program over different months.&lt;/P&gt;</description>
      <pubDate>Mon, 15 Jul 2019 12:59:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573479#M161910</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2019-07-15T12:59:36Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573485#M161911</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/281554"&gt;@PierreYvesILY&lt;/a&gt;&amp;nbsp;Is it possible for you to be more specific by giving examples of input data and the expected outcomes? There may or may not be an easy way out but until a more concrete example is seen it is hard to suggest. You may just stick to one month, "Month N/Structure/Data 1..x".&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Jul 2019 13:12:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573485#M161911</guid>
      <dc:creator>koyelghosh</dc:creator>
      <dc:date>2019-07-15T13:12:18Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573489#M161912</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/281554"&gt;@PierreYvesILY&lt;/a&gt;&amp;nbsp; Writing Pseudo-code/algorithm will help the readers. Somebody, who is not familiar with your code requirement, may find very hard to traverse through it and understand. The Pseudo-code/algorithm will help you as well and who knows may be you can solve the problem on your own. One thing I can say that currently this is a very long continuous code but may be I am wrong and the length suits the complexity of the problem. Pseudo-code/algorithm will help regardless but will mean more work from your side.&lt;/P&gt;</description>
      <pubDate>Mon, 15 Jul 2019 13:24:51 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573489#M161912</guid>
      <dc:creator>koyelghosh</dc:creator>
      <dc:date>2019-07-15T13:24:51Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573500#M161915</link>
      <description>&lt;P&gt;hello, thanks for responding.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here is the final type of outcome:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="SAS_#Board_StructureBeispiel.PNG" style="width: 600px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/31042iE978DD1C4F60D51D/image-size/large?v=v2&amp;amp;px=999" role="button" title="SAS_#Board_StructureBeispiel.PNG" alt="SAS_#Board_StructureBeispiel.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Auswertungmonat = Month ; it's a built parameter, I have to calculate it.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Source data : I have 3 sources, each of them coming from different applications, own logic, norms and reference.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;The global program treats first the data of the 1st source, and built the variables for the smallest level of the network (FILBEZ_BT).&lt;/P&gt;&lt;P&gt;Then data from the second source is processed and treated in such a way it can be merged with the 1st. ones.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Then the long SQL step I quoted in a preceding post take place and take the raw values to aggregate them and calculate some values of a lot of variables.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Afterwards the result table is merged with the 3 one which is delivered with the above structure directly and just needs to be merge each time at the right level.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Then all the tables (1 for each level) are added&amp;nbsp; one after the other to shape the global file.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The result of the all is the structure displayed above, WHERE only&amp;nbsp;2 entities of the smallest level are shown (Example and Group NL Example).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;i don't know if it is enough to understand.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for helping anyway&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Jul 2019 13:45:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573500#M161915</guid>
      <dc:creator>PierreYvesILY</dc:creator>
      <dc:date>2019-07-15T13:45:00Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573502#M161916</link>
      <description>&lt;P&gt;to the levels: FILBEZ_BT is the most detailed level, MBRBEZ_BT is a gathering of several FILBEZ_BT.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'll post an image of the desired result data file to make it clear.&lt;/P&gt;</description>
      <pubDate>Mon, 15 Jul 2019 13:47:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573502#M161916</guid>
      <dc:creator>PierreYvesILY</dc:creator>
      <dc:date>2019-07-15T13:47:57Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573601#M161983</link>
      <description>&lt;P&gt;Having many variables with a common base name differentiated by a suffix such as &lt;FONT face="Courier New"&gt;ORB_Anzahl_Akt_&amp;amp;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;Jahr11.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;often indicates that perhaps the data should have a separate variable, possibly named JAHR that would be used as BY variable to get calculations for each level of the variable for those calculations.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;I suspect proc summary and a data step with array code would be much cleaner .&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Jul 2019 16:55:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573601#M161983</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2019-07-15T16:55:52Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573770#M162041</link>
      <description>&lt;P&gt;hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks for your answer.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. The names of the variables with &amp;amp;Jahr11. and so forth are created exactly for the purpose of copying the results in separate columns in Excel afterwards.&lt;/P&gt;&lt;P&gt;2. I have to calculate evolutions in % between both years, so I build yearly variables to do so : &amp;nbsp;(Var&amp;amp;Jahr11.- Var&amp;nbsp;&amp;amp;Jahr12.)=Delta&amp;nbsp;&amp;amp;Jahr11. in %&lt;/P&gt;&lt;P&gt;If you can suggest a way to calculate the Delta with only one variable + an additional variable Jahr, I'd be pleased to use it.&lt;/P&gt;&lt;P&gt;It would simplify the code a LOT.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I don't understand what you mean by: proc summary and a data step with array code&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks and have a nice day&lt;/P&gt;&lt;P&gt;PY&lt;/P&gt;</description>
      <pubDate>Tue, 16 Jul 2019 08:21:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/573770#M162041</guid>
      <dc:creator>PierreYvesILY</dc:creator>
      <dc:date>2019-07-16T08:21:14Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/574023#M162114</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/281554"&gt;@PierreYvesILY&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;thanks for your answer.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;1. The names of the variables with &amp;amp;Jahr11. and so forth are created exactly for the purpose of copying the results in separate columns in Excel afterwards.&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000ff"&gt;&lt;STRONG&gt;2. I have to calculate evolutions in % between both years, so I build yearly variables to do so : &amp;nbsp;(Var&amp;amp;Jahr11.- Var&amp;nbsp;&amp;amp;Jahr12.)=Delta&amp;nbsp;&amp;amp;Jahr11. in %&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000ff"&gt;&lt;STRONG&gt;If you can suggest a way to calculate the Delta with only one variable + an additional variable Jahr, I'd be pleased to use it.&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;It would simplify the code a LOT.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I don't understand what you mean by: proc summary and a data step with array code&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;thanks and have a nice day&lt;/P&gt;
&lt;P&gt;PY&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Would have to see some example INPUT data to see what is possible.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Proc summary (or means) will group data and do sums (or other statistics) into the same variable with less fuss than SQL.&lt;/P&gt;
&lt;PRE&gt;proc summary data=  Liste_teil_5 nway;
   class STUFE MARKTREGION_BT NL_BT NLBEZ_BT MBRBEZ_BT;
   var  ORB_Anzahl_Akt_&amp;amp;Jahr11.  ORB_TVOL_Akt_&amp;amp;Jahr11.
        ORB_Anzahl_Akt_&amp;amp;Jahr11.    /* continue with all the 
                                   variables that need sums*/
   ;
   output out =temp  sum= ;
run;&lt;/PRE&gt;
&lt;P&gt;If it happens that you need every single one of your variables that start with ORB to be summed the above could reduce the VAR statement to something like:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp; var ORB: ;&lt;/P&gt;
&lt;P&gt;as proc summary/ means can use variable lists.&lt;/P&gt;
&lt;PRE&gt;proc summary data=  Liste_teil_5 nway;
   class STUFE MARKTREGION_BT NL_BT NLBEZ_BT MBRBEZ_BT;
   var  ORB: ngs: ;  
   output out =temp  sum= ;
run;&lt;/PRE&gt;
&lt;P&gt;The above would sum ALL numeric variables whose names start with ORB and NGS and place the sum in a variable of the same name in the output set.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Then a data step similar to:&lt;/P&gt;
&lt;PRE&gt;data want;
   set temp;
   /* calculate the rates*/
   array n &amp;lt;list the numerator variables&amp;gt;;
   array d &amp;lt;list the denominator variables in corresponding order&amp;gt;;
   array r &amp;lt;list the results variables of the rate calculations&amp;gt;;
   /* this do loop */
   do i= 1 to dim(n);
      r[i] = n[i] / d[i];
   end;
   /* would replace all of these */
   ORB_Anzahl_VZK_&amp;amp;Jahr11. =  ORB_Anzahl_Akt_&amp;amp;Jahr11./Anzahl_VZK_&amp;amp;Jahr11.;

   format orb: NGS: commax17.;
run;
&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp; I wasn't about to copy out all of your variable names.&lt;/P&gt;
&lt;P&gt;The ability to use variable lists in data step code can make things much simpler. If you need to process columns that appear in order you can use a list with two dashes in an array definition (or the var statement in Proc Summary / means).&lt;/P&gt;
&lt;P&gt;Example: if the variables ABC ABD ABQ BDD BDE are adjacent and I want to process them in some way in that order I could use an array definition of : array v&amp;nbsp;&amp;nbsp; ABC -- BDE;&lt;/P&gt;
&lt;P&gt;Also not the variable list in the Format statement much simpler. Or if I had a lot of variables to assign a format I might be tempted to use Proc Datasets after the set is created to assign the format instead of having so many &lt;FONT face="Courier New"&gt;format &lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;commax17. &lt;FONT color="#000000" face="arial,helvetica,sans-serif"&gt;&lt;FONT color="#333333" face="Helvetica"&gt;scattered through the code.&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 16 Jul 2019 21:55:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/574023#M162114</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2019-07-16T21:55:08Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/574076#M162137</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thank you for all this. I'll need some time to digest this and be able to move forward with my programm.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks a lot,&lt;BR /&gt;PY&lt;/P&gt;</description>
      <pubDate>Wed, 17 Jul 2019 07:07:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/574076#M162137</guid>
      <dc:creator>PierreYvesILY</dc:creator>
      <dc:date>2019-07-17T07:07:22Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/574122#M162164</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I sorted in the following table the type of data I have:&lt;/P&gt;&lt;P&gt;- yellow is alphanumeric&lt;/P&gt;&lt;P&gt;- blue is numeric&lt;/P&gt;&lt;P&gt;- from&amp;nbsp;Marktregion_BT until Filbez_bt, it's a cascade of entities, each one being a substructure of the previous one&lt;/P&gt;&lt;P&gt;- Stufe is a generic variable to select the accurate level of data, and also give the last level : AG (being the summary of all Marktregion_BT). It means that when 'MBR' is selected, all FILBEZ_BT values are empty, as the FIL are the level below MBR. When NL is selected, the MBRBEZ_BT and FILBEZ_BT values are empty etc.&lt;/P&gt;&lt;P&gt;- the yellow columns give the 'type' of data I find, not the dependencies between the columns.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Datadashboard1.PNG" style="width: 600px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/31084iE05B92646DB60EDE/image-size/large?v=v2&amp;amp;px=999" role="button" title="Datadashboard1.PNG" alt="Datadashboard1.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;I need to:&lt;/P&gt;&lt;P&gt;- calculate the sum of each variable VAR1, VAR2... for each level Filbez_bt till Marktregion_bt &lt;U&gt;AND&lt;/U&gt; each STUFE, for each year ('JAHR), and each month ('MONAT'), and with additional selections like: all Plattform values / Plattform = O / Plattform = F AND AMPEL = OFFEN or GRUEN or AMPEL = all values. Each new variable (= result variable) has to be named in a customized way&lt;/P&gt;&lt;P&gt;- calculate the evolutions 2019/2018 for each result variable.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My original program works but is very heavy and obviously can be optimized, as I'm new to SAS I'm learning by doing, quite slowly.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'd appreciate any suggestion to solve the many problems mentioned above.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks a lot,&lt;/P&gt;&lt;P&gt;PY&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 17 Jul 2019 10:29:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/574122#M162164</guid>
      <dc:creator>PierreYvesILY</dc:creator>
      <dc:date>2019-07-17T10:29:06Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/574994#M162543</link>
      <description>&lt;P&gt;hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I used the recommended code and it worked perffecly well.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I now have to treat other problems.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks a lot&lt;/P&gt;&lt;P&gt;PY&lt;/P&gt;</description>
      <pubDate>Fri, 19 Jul 2019 15:52:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/574994#M162543</guid>
      <dc:creator>PierreYvesILY</dc:creator>
      <dc:date>2019-07-19T15:52:54Z</dc:date>
    </item>
    <item>
      <title>Re: processing a variable number of programm blocs after one another</title>
      <link>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/575017#M162560</link>
      <description>&lt;P&gt;It appears that you are looking for different combinations of summaries. That might make proc summary even more attractive.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please examine the output data set from this code:&lt;/P&gt;
&lt;PRE&gt;proc summary data=sashelp.class;
   class sex age;
   var height;
   output out=work.classsummary  mean=;
run;&lt;/PRE&gt;
&lt;P&gt;You will see a variable called _type_ that in this case has values from 0 to 3. The _type_=0 is the summary, mean in this case, across all records in the data set; _type_=1 is the summary only for the levels of Age; _type_ =2 is the summary for levels of Sex&amp;nbsp;; _type_=3 is the summary for the combined levels of sex and age.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you have a variable that has missing values that you want considered as a separate level then you use the option /missing on a class statement. You can have more than one class statement with different options but ALL of the variables on the class statements will be used to get different summaries.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you only want specific records after a summary step then a data step can select or modify.&lt;/P&gt;
&lt;P&gt;You can also summarize many variables and request different statistics. The /autoname option on the OUTPUT statement creates output variables with the statistic appended to the variable name if you don't want to create different variables by hand.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you have actual SAS date values you can use the format applied to a variable to create groups. ( and a WHERE to restrict the range if desired). You should have the SASHELP.STOCKS data set available to see this code. I am creating a custom date format as the SAS supplied YYMM format places an M in the value. Note that the first proc summary step creates a summary of the overall min and max of all of the stock open and close values&amp;nbsp;over the period of time in the data; a summary by calendar month of min and max open and close across all stocks, the min and max of the stock open and close across the time period and the min and max open and close value for each stock and month combination.&lt;/P&gt;
&lt;P&gt;The second proc summary does the exact same thing but groups by calendar quarter instead of month. A different format could do the same for calendar years. Custom formats could be made for many types of intervals not supplied by SAS using Proc Format and some ingenuity.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;proc format library=work;
picture my_ym  (default=6)
low-high='%Y%0m' (datatype=date);
run;

proc summary data=sashelp.stocks;
   class stock date;
   format date  my_ym.;
   var open close;
   output out=work.stocksummary min= max= /autoname;
run;

proc summary data=sashelp.stocks;
   class stock date;
   format date  yyq6.;
   var open close;
   output out=work.stocksummary2 min= max= /autoname;
run;&lt;/PRE&gt;</description>
      <pubDate>Fri, 19 Jul 2019 17:49:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/processing-a-variable-number-of-programm-blocs-after-one-another/m-p/575017#M162560</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2019-07-19T17:49:25Z</dc:date>
    </item>
  </channel>
</rss>

