Pokaż
Ignoruj:
Data:
2009-01-20 21:55:04 (17 years ago)
Autor:
dorota
Opis:

re #43 raport RankingKlientow?2009 z uwzglednieniem korekt

Pliki:
1 zmodyfikowane

Legenda:

Bez zmian
Dodane
Usunięte
  • trunk/RaportySQL/RankingKlientow2009.rdl

    r185 r222  
    7676          <rd:TypeName>System.Decimal</rd:TypeName> 
    7777        </Field> 
    78         <Field Name="ILOSC"> 
    79           <DataField>ILOSC</DataField> 
    80           <rd:TypeName>System.Int32</rd:TypeName> 
    81         </Field> 
    8278        <Field Name="symbol"> 
    8379          <DataField>Symbol</DataField> 
     
    111107      <Query> 
    112108        <DataSourceName>BAZA_REKLAM</DataSourceName> 
    113         <CommandText>SELECT     K.FirstName, K.LastName, CONVERT(money, SUM(FD.NETTO)) AS WARTOSC, COUNT(DISTINCT FD.reklamaId) AS ILOSC, A1.Symbol,  
    114                       YEAR(F.DATA_WYSTAWIENIA) AS rok, A2.Symbol AS agencja 
     109        <CommandText>SELECT     K.FirstName, K.LastName, CONVERT(money, SUM(FD.netto)) AS WARTOSC, A1.Symbol, YEAR(F.DATA_WYSTAWIENIA) AS rok,  
     110                      A2.Symbol AS agencja 
    115111FROM         FAKTURY AS F LEFT OUTER JOIN 
    116                       FAKTURA_DETAILS AS FD ON F.ID_FAKTURY = FD.ID_FAKTURY LEFT OUTER JOIN 
     112                      VIEW_BRUTTO_PO_KOREKTACH AS FD ON F.ID_FAKTURY = FD.id_faktury LEFT OUTER JOIN 
    117113                      KLIENCI AS K ON F.ID_NABYWCY = K.CustomerID INNER JOIN 
    118114                      AGENCI AS A1 ON F.NUMER_ROZ = A1.F_ROZ INNER JOIN 
     
    120116WHERE     (F.NUMER_ROZ &lt;&gt; 'POZ') AND (F.NUMER_ROZ &lt;&gt; 'KAT') AND (YEAR(F.DATA_WYSTAWIENIA) &gt; 2008) 
    121117GROUP BY K.FirstName, K.LastName, A1.Symbol, YEAR(F.DATA_WYSTAWIENIA), A2.Symbol 
    122 ORDER BY CONVERT(money, SUM(FD.NETTO)) DESC</CommandText> 
     118ORDER BY CONVERT(money, SUM(FD.netto)) DESC</CommandText> 
    123119      </Query> 
    124120    </DataSet> 
     
    216212                        <PaddingBottom>2pt</PaddingBottom> 
    217213                      </Style> 
    218                       <ZIndex>5</ZIndex> 
     214                      <ZIndex>4</ZIndex> 
    219215                      <CanGrow>true</CanGrow> 
    220216                      <Value>=Fields!FirstName.Value</Value> 
     
    244240                        <PaddingBottom>2pt</PaddingBottom> 
    245241                      </Style> 
    246                       <ZIndex>4</ZIndex> 
     242                      <ZIndex>3</ZIndex> 
    247243                      <CanGrow>true</CanGrow> 
    248244                      <Value>=Fields!Lastname.Value</Value> 
     
    274270                        <Language>pl</Language> 
    275271                      </Style> 
    276                       <ZIndex>3</ZIndex> 
     272                      <ZIndex>2</ZIndex> 
    277273                      <CanGrow>true</CanGrow> 
    278274                      <Value>=Fields!WARTOSC.Value</Value> 
    279                     </Textbox> 
    280                   </ReportItems> 
    281                 </TableCell> 
    282                 <TableCell> 
    283                   <ReportItems> 
    284                     <Textbox Name="ILOSC"> 
    285                       <rd:DefaultName>ILOSC</rd:DefaultName> 
    286                       <Style> 
    287                         <BorderColor> 
    288                           <Default>LightGrey</Default> 
    289                         </BorderColor> 
    290                         <BorderStyle> 
    291                           <Default>Solid</Default> 
    292                         </BorderStyle> 
    293                         <BorderWidth> 
    294                           <Default>0.5pt</Default> 
    295                         </BorderWidth> 
    296                         <FontSize>8pt</FontSize> 
    297                         <TextAlign>Center</TextAlign> 
    298                         <VerticalAlign>Middle</VerticalAlign> 
    299                         <PaddingLeft>2pt</PaddingLeft> 
    300                         <PaddingRight>2pt</PaddingRight> 
    301                         <PaddingTop>2pt</PaddingTop> 
    302                         <PaddingBottom>2pt</PaddingBottom> 
    303                       </Style> 
    304                       <ZIndex>2</ZIndex> 
    305                       <CanGrow>true</CanGrow> 
    306                       <Value>=Fields!ILOSC.Value</Value> 
    307275                    </Textbox> 
    308276                  </ReportItems> 
     
    396364                        <PaddingBottom>2pt</PaddingBottom> 
    397365                      </Style> 
    398                       <ZIndex>10</ZIndex> 
     366                      <ZIndex>8</ZIndex> 
    399367                      <CanGrow>true</CanGrow> 
    400368                      <Value>KLIENT</Value> 
     
    426394                        <PaddingBottom>2pt</PaddingBottom> 
    427395                      </Style> 
    428                       <ZIndex>9</ZIndex> 
     396                      <ZIndex>7</ZIndex> 
    429397                      <CanGrow>true</CanGrow> 
    430398                      <Value>WARTOŚĆ</Value> 
    431                     </Textbox> 
    432                   </ReportItems> 
    433                 </TableCell> 
    434                 <TableCell> 
    435                   <ReportItems> 
    436                     <Textbox Name="textbox11"> 
    437                       <rd:DefaultName>textbox11</rd:DefaultName> 
    438                       <Style> 
    439                         <BackgroundColor>WhiteSmoke</BackgroundColor> 
    440                         <BorderColor> 
    441                           <Default>LightGrey</Default> 
    442                         </BorderColor> 
    443                         <BorderStyle> 
    444                           <Default>Solid</Default> 
    445                         </BorderStyle> 
    446                         <BorderWidth> 
    447                           <Default>0.5pt</Default> 
    448                         </BorderWidth> 
    449                         <FontSize>8pt</FontSize> 
    450                         <FontWeight>700</FontWeight> 
    451                         <TextAlign>Center</TextAlign> 
    452                         <VerticalAlign>Middle</VerticalAlign> 
    453                         <PaddingLeft>2pt</PaddingLeft> 
    454                         <PaddingRight>2pt</PaddingRight> 
    455                         <PaddingTop>2pt</PaddingTop> 
    456                         <PaddingBottom>2pt</PaddingBottom> 
    457                       </Style> 
    458                       <ZIndex>8</ZIndex> 
    459                       <CanGrow>true</CanGrow> 
    460                       <Value>ILOŚĆ</Value> 
    461399                    </Textbox> 
    462400                  </ReportItems> 
     
    486424                        <PaddingBottom>2pt</PaddingBottom> 
    487425                      </Style> 
    488                       <ZIndex>7</ZIndex> 
     426                      <ZIndex>6</ZIndex> 
    489427                      <CanGrow>true</CanGrow> 
    490428                      <Value>AGENT</Value> 
     
    516454                        <PaddingBottom>2pt</PaddingBottom> 
    517455                      </Style> 
    518                       <ZIndex>6</ZIndex> 
     456                      <ZIndex>5</ZIndex> 
    519457                      <CanGrow>true</CanGrow> 
    520458                      <Value>AGENCJA</Value> 
     
    529467        <TableColumns> 
    530468          <TableColumn> 
    531             <Width>4cm</Width> 
     469            <Width>5cm</Width> 
    532470          </TableColumn> 
    533471          <TableColumn> 
    534             <Width>3.75cm</Width> 
     472            <Width>4.5cm</Width> 
    535473          </TableColumn> 
    536474          <TableColumn> 
    537             <Width>2.5cm</Width> 
    538           </TableColumn> 
    539           <TableColumn> 
    540             <Width>2.5cm</Width> 
     475            <Width>3.25cm</Width> 
    541476          </TableColumn> 
    542477          <TableColumn>