﻿<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright Archdiocese of Cincinnati use with permission only c/o bmaly@CatholicAOC.org-->
<Report MustUnderstand="df" xmlns="http://schemas.microsoft.com/sqlserver/reporting/2016/01/reportdefinition" xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner" xmlns:df="http://schemas.microsoft.com/sqlserver/reporting/2016/01/reportdefinition/defaultfontfamily">
  <df:DefaultFontFamily>Segoe UI</df:DefaultFontFamily>
  <AutoRefresh>0</AutoRefresh>
  <DataSources>
    <DataSource Name="AOC">
      <DataSourceReference>AOCds</DataSourceReference>
      <rd:SecurityType>DataBase</rd:SecurityType>
      <rd:DataSourceID>ca9db7bd-b480-4ad8-9c6d-7d50827b04a5</rd:DataSourceID>
    </DataSource>
  </DataSources>
  <DataSets>
    <DataSet Name="MyChurches">
      <Query>
        <DataSourceName>AOC</DataSourceName>
        <CommandText>SELECT
  c.ChurchID
  ,c.ChurchName+ ' - ' + isnull(c.City,'') [ChurchName]
FROM
  xrpt.Churches_vw AS c
	--join xrpt.ChurchUsers_vw cu 
	--on c.ChurchID = cu.ChurchID and cu.UserName=@CurrentUser 
	--and (cu.ChurchAdministrator = 1 or cu.FundManager = 1)
order by c.ChurchName+ ' - ' + isnull(c.City,'')</CommandText>
        <rd:UseGenericDesigner>true</rd:UseGenericDesigner>
      </Query>
      <Fields>
        <Field Name="ChurchID">
          <DataField>ChurchID</DataField>
          <rd:TypeName>System.Int32</rd:TypeName>
        </Field>
        <Field Name="ChurchName">
          <DataField>ChurchName</DataField>
          <rd:TypeName>System.String</rd:TypeName>
        </Field>
      </Fields>
    </DataSet>
    <DataSet Name="Audit">
      <Query>
        <DataSourceName>AOC</DataSourceName>
        <QueryParameters>
          <QueryParameter Name="@ATTR">
            <Value>=Parameters!ATTR.Value</Value>
          </QueryParameter>
          <QueryParameter Name="@ChurchID">
            <Value>=Parameters!ChurchID.Value</Value>
          </QueryParameter>
          <QueryParameter Name="@DateFrom">
            <Value>=Parameters!DateFrom.Value</Value>
          </QueryParameter>
          <QueryParameter Name="@DateTo">
            <Value>=Parameters!DateTo.Value</Value>
          </QueryParameter>
        </QueryParameters>
        <CommandText>--declare @churchid int = 84
--declare @datefrom date = '2021/01/01'
--declare @dateto date ='2021/12/30'
--declare @ATTR int = 0 --1 selects the AOC attributes and 0 selects parish

declare @Patts table (FundID int, AttributeSelected varchar(200), AOCAttribute varchar(200), ParishAttribute varchar(200),SORT varchar(200))
insert into @Patts
Select FundID
,AttributeSelected = case when @ATTR=1 then ( isnull(STUFF((SELECT top 1 ', ' + isnull(fa.AttributeValue ,'')
	FROM xrpt.FundAttributes_vw fa
	WHERE  f.FundID=fa.FundID
	and f.churchid= fa.churchid 
	and fa.systemID='Gabriel' and fa.AttributeName = 'AOC'
	FOR XML PATH ('')), 1, 1, '') ,''))
	else ( isnull(STUFF((SELECT top 1 ', ' + isnull(fa.AttributeValue ,'')
	FROM xrpt.FundAttributes_vw fa
	WHERE  f.FundID=fa.FundID
	and f.churchid= fa.churchid 
	and fa.systemID='Gabriel' and fa.AttributeName = 'Parish'
	FOR XML PATH ('')), 1, 1, '') ,
	( isnull(STUFF((SELECT top 1 ', ' + isnull(fa.AttributeValue ,'')
	FROM xrpt.FundAttributes_vw fa
	WHERE  f.FundID=fa.FundID
	and f.churchid= fa.churchid 
	and fa.systemID='Gabriel' and fa.AttributeName = 'AOC'
	FOR XML PATH ('')), 1, 1, '') ,''))
	)) end
,AOCattribute = ( isnull(STUFF((SELECT top 1 ', ' + isnull(fa.AttributeValue ,'')
	FROM xrpt.FundAttributes_vw fa
	WHERE  f.FundID=fa.FundID
	and f.churchid= fa.churchid 
	and fa.systemID='Gabriel' and fa.AttributeName = 'AOC'
	FOR XML PATH ('')), 1, 1, '') ,''))
,ParishAttribute = ( isnull(STUFF((SELECT top 1 ', ' + isnull(fa.AttributeValue ,'')
	FROM xrpt.FundAttributes_vw fa
	WHERE  f.FundID=fa.FundID
	and f.churchid= fa.churchid 
	and fa.systemID='Gabriel' and fa.AttributeName = 'Parish'
	FOR XML PATH ('')), 1, 1, '') ,'')) 
,SORT = ( isnull(STUFF((SELECT top 1 ', ' + isnull(fa.AttributeValue ,'')
	FROM xrpt.FundAttributes_vw fa
	WHERE  f.FundID=fa.FundID
	and f.churchid= fa.churchid 
	and fa.systemID='Gabriel' and fa.AttributeName = 'SORT'
	FOR XML PATH ('')), 1, 1, '') ,'')) 
from xrpt.Funds_vw f
	where ChurchID=@ChurchID

select
f.ChurchID
,c.ChurchName
,f.FundID
,Convert(varchar(4),f.ChurchID)+'-'+Convert(varchar(6),f.FundID) CollectionExportName
,f.FundDescription 
,isnull(f.AnnualContributionBucket,'') AnnualContributionBucket
,f.StatusCode
,pa.AttributeSelected
,pa.AOCAttribute
,pa.ParishAttribute
,pa.SORT
--,isnull(year(contributiondate),0) [year]
,GrossAmount = isnull( (Select sum(GrossAmount) 
	from xrpt.FundContributions_vw fc
	Where f.FundID=fc.FundID
	and f.ChurchID=fc.ChurchID
	and ContributionDate between @DateFrom and @DateTo),0)
,LastContribution= (Select Max(ContributionDate)
	from xrpt.FundContributions_vw fc
	Where f.FundID=fc.FundID
	and f.ChurchID=fc.ChurchID)
from xrpt.Funds_vw f 
join xrpt.churches_vw c
on c.ChurchID=F.ChurchID
join @Patts pa on pa.FundID=f.FundID

where c.churchid =@ChurchID
group by f.ChurchID
,c.ChurchName
,f.FundID
,Convert(varchar(4),f.ChurchID)+'-'+Convert(varchar(6),f.FundID) 
,f.FundDescription 
,f.AnnualContributionBucket
,f.StatusCode
,pa.AttributeSelected
,pa.AOCAttribute
,pa.ParishAttribute
,pa.SORT
--,year(contributiondate) 
order by f.FundDescription</CommandText>
        <rd:UseGenericDesigner>true</rd:UseGenericDesigner>
      </Query>
      <Fields>
        <Field Name="ChurchID">
          <DataField>ChurchID</DataField>
          <rd:TypeName>System.Int32</rd:TypeName>
        </Field>
        <Field Name="ChurchName">
          <DataField>ChurchName</DataField>
          <rd:TypeName>System.String</rd:TypeName>
        </Field>
        <Field Name="fundid">
          <DataField>FundID</DataField>
          <rd:TypeName>System.Int32</rd:TypeName>
        </Field>
        <Field Name="FundDescription">
          <DataField>FundDescription</DataField>
          <rd:TypeName>System.String</rd:TypeName>
        </Field>
        <Field Name="CollectionExportName">
          <DataField>CollectionExportName</DataField>
          <rd:TypeName>System.String</rd:TypeName>
        </Field>
        <Field Name="AnnualContributionBucket">
          <DataField>AnnualContributionBucket</DataField>
          <rd:TypeName>System.Int32</rd:TypeName>
        </Field>
        <Field Name="StatusCode">
          <DataField>StatusCode</DataField>
          <rd:TypeName>System.String</rd:TypeName>
        </Field>
        <Field Name="AttributeSelected">
          <DataField>AttributeSelected</DataField>
          <rd:TypeName>System.String</rd:TypeName>
        </Field>
        <Field Name="GrossAmount">
          <DataField>GrossAmount</DataField>
          <rd:TypeName>System.Decimal</rd:TypeName>
        </Field>
        <Field Name="AOCAttribute">
          <DataField>AOCAttribute</DataField>
          <rd:TypeName>System.String</rd:TypeName>
        </Field>
        <Field Name="SORT">
          <DataField>SORT</DataField>
          <rd:TypeName>System.String</rd:TypeName>
        </Field>
        <Field Name="LastContribution">
          <DataField>LastContribution</DataField>
          <rd:TypeName>System.DateTime</rd:TypeName>
        </Field>
        <Field Name="ParishAttribute">
          <DataField>ParishAttribute</DataField>
          <rd:TypeName>System.String</rd:TypeName>
        </Field>
      </Fields>
    </DataSet>
  </DataSets>
  <ReportSections>
    <ReportSection>
      <Body>
        <ReportItems>
          <Tablix Name="Tablix4">
            <TablixBody>
              <TablixColumns>
                <TablixColumn>
                  <Width>1in</Width>
                </TablixColumn>
                <TablixColumn>
                  <Width>2.74166in</Width>
                </TablixColumn>
                <TablixColumn>
                  <Width>0.76042in</Width>
                </TablixColumn>
                <TablixColumn>
                  <Width>0.64583in</Width>
                </TablixColumn>
                <TablixColumn>
                  <Width>1.4375in</Width>
                </TablixColumn>
                <TablixColumn>
                  <Width>1.46875in</Width>
                </TablixColumn>
                <TablixColumn>
                  <Width>1.6875in</Width>
                </TablixColumn>
                <TablixColumn>
                  <Width>0.78125in</Width>
                </TablixColumn>
                <TablixColumn>
                  <Width>0.91667in</Width>
                </TablixColumn>
                <TablixColumn>
                  <Width>0.84375in</Width>
                </TablixColumn>
              </TablixColumns>
              <TablixRows>
                <TablixRow>
                  <Height>0.55in</Height>
                  <TablixCells>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="Textbox1">
                          <CanGrow>true</CanGrow>
                          <UserSort>
                            <SortExpression>=Fields!fundid.Value</SortExpression>
                          </UserSort>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>Collection Export Name</Value>
                                  <Style />
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>Textbox1</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="Textbox4">
                          <CanGrow>true</CanGrow>
                          <UserSort>
                            <SortExpression>=Fields!FundDescription.Value</SortExpression>
                          </UserSort>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>Fund Description</Value>
                                  <Style />
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>Textbox4</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="Textbox3">
                          <CanGrow>true</CanGrow>
                          <UserSort>
                            <SortExpression>=Fields!StatusCode.Value</SortExpression>
                          </UserSort>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>Status Code</Value>
                                  <Style />
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>Textbox3</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="Textbox5">
                          <CanGrow>true</CanGrow>
                          <UserSort>
                            <SortExpression>=Fields!SORT.Value</SortExpression>
                          </UserSort>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>SORT</Value>
                                  <Style />
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>Textbox5</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="Textbox2">
                          <CanGrow>true</CanGrow>
                          <UserSort>
                            <SortExpression>=Fields!AttributeSelected.Value</SortExpression>
                          </UserSort>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>Attribute Selected</Value>
                                  <Style />
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>Textbox2</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="Textbox7">
                          <CanGrow>true</CanGrow>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>Parish Attribute</Value>
                                  <Style />
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>Textbox7</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="Textbox9">
                          <CanGrow>true</CanGrow>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>AOCAttribute</Value>
                                  <Style />
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>Textbox9</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="Textbox35">
                          <CanGrow>true</CanGrow>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>Annual Contribution Bucket</Value>
                                  <Style>
                                    <FontFamily>Arial</FontFamily>
                                  </Style>
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>Textbox35</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="Textbox31">
                          <CanGrow>true</CanGrow>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>Period </Value>
                                  <Style>
                                    <FontFamily>Arial</FontFamily>
                                  </Style>
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>Total</Value>
                                  <Style>
                                    <FontFamily>Arial</FontFamily>
                                  </Style>
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>Textbox31</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="Textbox6">
                          <CanGrow>true</CanGrow>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>Last Contribution</Value>
                                  <Style>
                                    <FontFamily>Arial</FontFamily>
                                  </Style>
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>Textbox6</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                  </TablixCells>
                </TablixRow>
                <TablixRow>
                  <Height>0.25in</Height>
                  <TablixCells>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="CollectionExportName">
                          <CanGrow>true</CanGrow>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>=Fields!CollectionExportName.Value</Value>
                                  <Style>
                                    <FontWeight>Bold</FontWeight>
                                    <TextDecoration>None</TextDecoration>
                                  </Style>
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>CollectionExportName</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="FundDescription">
                          <CanGrow>true</CanGrow>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>=Fields!FundDescription.Value</Value>
                                  <MarkupType>HTML</MarkupType>
                                  <Style>
                                    <FontWeight>Bold</FontWeight>
                                    <TextDecoration>Underline</TextDecoration>
                                    <Color>Blue</Color>
                                  </Style>
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>FundDescription</rd:DefaultName>
                          <ActionInfo>
                            <Actions>
                              <Action>
                                <Hyperlink>="https://app.gabrielsoft.com/auth/ohcndiocese/" &amp; Parameters!ChurchID.Value &amp; "/Fund/Edit/" &amp;Fields!fundid.Value</Hyperlink>
                              </Action>
                            </Actions>
                          </ActionInfo>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="StatusCode">
                          <CanGrow>true</CanGrow>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>=Fields!StatusCode.Value</Value>
                                  <Style />
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>StatusCode</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="SORT">
                          <CanGrow>true</CanGrow>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>=Fields!SORT.Value</Value>
                                  <Style />
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>SORT</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="AttributeSelected">
                          <CanGrow>true</CanGrow>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>=Fields!AttributeSelected.Value</Value>
                                  <Style />
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>AttributeSelected</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="ParishAttribute">
                          <CanGrow>true</CanGrow>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>=Fields!ParishAttribute.Value</Value>
                                  <Style />
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>ParishAttribute</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="AOCAttribute">
                          <CanGrow>true</CanGrow>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>=Fields!AOCAttribute.Value</Value>
                                  <Style />
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>AOCAttribute</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="AnnualContributionBucket">
                          <CanGrow>true</CanGrow>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>=Fields!AnnualContributionBucket.Value</Value>
                                  <Style>
                                    <FontFamily>Arial</FontFamily>
                                  </Style>
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>AnnualContributionBucket</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="GrossAmount">
                          <CanGrow>true</CanGrow>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>=Fields!GrossAmount.Value</Value>
                                  <Style>
                                    <FontFamily>Arial</FontFamily>
                                    <Format>n2</Format>
                                  </Style>
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>GrossAmount</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                    <TablixCell>
                      <CellContents>
                        <Textbox Name="LastContribution">
                          <CanGrow>true</CanGrow>
                          <KeepTogether>true</KeepTogether>
                          <Paragraphs>
                            <Paragraph>
                              <TextRuns>
                                <TextRun>
                                  <Value>=Fields!LastContribution.Value</Value>
                                  <Style>
                                    <FontFamily>Arial</FontFamily>
                                    <Format>MM/dd/yyyy</Format>
                                  </Style>
                                </TextRun>
                              </TextRuns>
                              <Style />
                            </Paragraph>
                          </Paragraphs>
                          <rd:DefaultName>LastContribution</rd:DefaultName>
                          <Style>
                            <Border>
                              <Color>LightGrey</Color>
                              <Style>Solid</Style>
                            </Border>
                            <PaddingLeft>2pt</PaddingLeft>
                            <PaddingRight>2pt</PaddingRight>
                            <PaddingTop>2pt</PaddingTop>
                            <PaddingBottom>2pt</PaddingBottom>
                          </Style>
                        </Textbox>
                      </CellContents>
                    </TablixCell>
                  </TablixCells>
                </TablixRow>
              </TablixRows>
            </TablixBody>
            <TablixColumnHierarchy>
              <TablixMembers>
                <TablixMember />
                <TablixMember />
                <TablixMember />
                <TablixMember />
                <TablixMember />
                <TablixMember />
                <TablixMember />
                <TablixMember />
                <TablixMember />
                <TablixMember />
              </TablixMembers>
            </TablixColumnHierarchy>
            <TablixRowHierarchy>
              <TablixMembers>
                <TablixMember>
                  <KeepWithGroup>After</KeepWithGroup>
                </TablixMember>
                <TablixMember>
                  <Group Name="Details4" />
                </TablixMember>
              </TablixMembers>
            </TablixRowHierarchy>
            <DataSetName>Audit</DataSetName>
            <PageName>Summary</PageName>
            <Top>0.91944in</Top>
            <Height>0.8in</Height>
            <Width>12.28333in</Width>
            <Style>
              <Border>
                <Style>None</Style>
              </Border>
            </Style>
          </Tablix>
          <Textbox Name="FundName">
            <CanGrow>true</CanGrow>
            <KeepTogether>true</KeepTogether>
            <Paragraphs>
              <Paragraph>
                <TextRuns>
                  <TextRun>
                    <Value>=str(Parameters!ChurchID.Value) &amp; " - " &amp; First(Fields!ChurchName.Value, "Audit") &amp; Chr(10) &amp; Chr(10) 
&amp;"For the period: "&amp; FormatDateTime(Parameters!DateFrom.Value,DateFormat.ShortDate) &amp; " through " &amp; FormatDateTime(Parameters!DateTo.Value,DateFormat.ShortDate) 
&amp; Chr(10) &amp; "" 
&amp; Chr(10) &amp; "This will provide a listing of the funds and total contributions for the selected date range. "  
&amp; Chr(10) &amp; "For Funds that are not being used, or only used for certain time of the year, it is suggested that these be set to inactive in Gabriel. "</Value>
                    <Style>
                      <FontFamily>Arial</FontFamily>
                    </Style>
                  </TextRun>
                </TextRuns>
                <Style />
              </Paragraph>
            </Paragraphs>
            <Height>0.91944in</Height>
            <Width>12.28333in</Width>
            <ZIndex>1</ZIndex>
            <Style>
              <Border>
                <Style>None</Style>
              </Border>
              <VerticalAlign>Bottom</VerticalAlign>
              <PaddingLeft>2pt</PaddingLeft>
              <PaddingRight>2pt</PaddingRight>
              <PaddingTop>2pt</PaddingTop>
              <PaddingBottom>2pt</PaddingBottom>
            </Style>
          </Textbox>
        </ReportItems>
        <Height>1.71944in</Height>
        <Style>
          <Border>
            <Style>None</Style>
          </Border>
        </Style>
      </Body>
      <Width>12.28333in</Width>
      <Page>
        <LeftMargin>1in</LeftMargin>
        <RightMargin>1in</RightMargin>
        <TopMargin>1in</TopMargin>
        <BottomMargin>1in</BottomMargin>
        <Style />
      </Page>
    </ReportSection>
  </ReportSections>
  <ReportParameters>
    <ReportParameter Name="ChurchID">
      <DataType>Integer</DataType>
      <Prompt>Select Church</Prompt>
      <ValidValues>
        <DataSetReference>
          <DataSetName>MyChurches</DataSetName>
          <ValueField>ChurchID</ValueField>
          <LabelField>ChurchName</LabelField>
        </DataSetReference>
      </ValidValues>
    </ReportParameter>
    <ReportParameter Name="CurrentUser">
      <DataType>String</DataType>
      <DefaultValue>
        <Values>
          <Value>=User!UserID</Value>
        </Values>
      </DefaultValue>
      <Prompt>Current User</Prompt>
      <Hidden>true</Hidden>
    </ReportParameter>
    <ReportParameter Name="DateFrom">
      <DataType>DateTime</DataType>
      <Prompt>Begin Date</Prompt>
    </ReportParameter>
    <ReportParameter Name="DateTo">
      <DataType>DateTime</DataType>
      <Prompt>End Date</Prompt>
    </ReportParameter>
    <ReportParameter Name="ATTR">
      <DataType>String</DataType>
      <DefaultValue>
        <Values>
          <Value>0</Value>
        </Values>
      </DefaultValue>
      <Prompt>Attribute TEST</Prompt>
      <ValidValues>
        <ParameterValues>
          <ParameterValue>
            <Value>0</Value>
            <Label>Parish</Label>
          </ParameterValue>
          <ParameterValue>
            <Value>1</Value>
            <Label>AOC</Label>
          </ParameterValue>
        </ParameterValues>
      </ValidValues>
    </ReportParameter>
  </ReportParameters>
  <ReportParametersLayout>
    <GridLayoutDefinition>
      <NumberOfColumns>4</NumberOfColumns>
      <NumberOfRows>4</NumberOfRows>
      <CellDefinitions>
        <CellDefinition>
          <ColumnIndex>0</ColumnIndex>
          <RowIndex>0</RowIndex>
          <ParameterName>ChurchID</ParameterName>
        </CellDefinition>
        <CellDefinition>
          <ColumnIndex>0</ColumnIndex>
          <RowIndex>2</RowIndex>
          <ParameterName>CurrentUser</ParameterName>
        </CellDefinition>
        <CellDefinition>
          <ColumnIndex>2</ColumnIndex>
          <RowIndex>2</RowIndex>
          <ParameterName>DateFrom</ParameterName>
        </CellDefinition>
        <CellDefinition>
          <ColumnIndex>3</ColumnIndex>
          <RowIndex>2</RowIndex>
          <ParameterName>DateTo</ParameterName>
        </CellDefinition>
        <CellDefinition>
          <ColumnIndex>0</ColumnIndex>
          <RowIndex>3</RowIndex>
          <ParameterName>ATTR</ParameterName>
        </CellDefinition>
      </CellDefinitions>
    </GridLayoutDefinition>
  </ReportParametersLayout>
  <rd:ReportUnitType>Inch</rd:ReportUnitType>
  <rd:ReportID>8f51e90d-03ad-4d71-a959-99ce486f8559</rd:ReportID>
</Report>