WebI报表设计高级功能.ppt
WebI报表设计高级功能(BW320)SAP BO顾问顾问 2010年年09月月09日日议 程n复习WebI报表设计基础课程n高级报表查询技术n使用计算上下文n利用字符和时间函数创建公式n使用IF逻辑n高级报表展现技术n使用超链接n实践练习,测试实践练习,测试Web Intelligence定位nSAP BI模块报表解决方案的一部分n快速获取信息以帮助决策n即席查询(ad-hoc query)SAP 2008/Page 3Web Intelligence数据读取流程 SAP 2008/Page 4习题1.What is a universe?2.List the object types used in a universe,and the kind of data returned by each type?3.What is the difference between a query filter and a report filter?4.What are the three components that make up a Web Intelligence document?5.What are the differences between applying breaks and sections to a report?6.What is a Scope of Analysis for a query?SAPPHIRE 2008 OR 4238/Page 5习题答案:1.What is a universe?1.What is a universe?Answer:A universe is the BusinessObjects semantic layer that maps to data in a database and is used for creating queries in Web Intelligence.2.List the object types used in a BusinessObjects universe,and the kind of data 2.List the object types used in a BusinessObjects universe,and the kind of data returned by each type.returned by each type.Answer:Dimension objects:Character-type data,dates,and non-aggregated numeric data,for example telephone numbers.Dimensions are the key elements of a query.Measure objects:Numeric-or fact-type dataDetail objects:Character-or date-type data(supplementary information)SAPPHIRE 2008 OR 4238/Page 6习题答案:3.What is the difference between a query filter and a report filter?3.What is the difference between a query filter and a report filter?Answer:A query filter is created in the Query panel to limit the data retrieved from the database;a report filter is created in the Web Intelligence Rich Client window and allows you to restrict the data shown in the report simply by hiding the data you are not interested in.4.What are the three components that make up a Web Intelligence document?4.What are the three components that make up a Web Intelligence document?Answer:Reports,blocks(tables and charts),and the microcube of data SAPPHIRE 2008 OR 4238/Page 7习题答案:5.What are the differences between applying breaks and sections to a report?5.What are the differences between applying breaks and sections to a report?Answer:The difference is that the grouped value appears as a header outside the block instead of remaining within the block.A break only groups within a block,whereas sectioning groups the entire report.SAPPHIRE 2008 OR 4238/Page 8习题答案:6.What is a Scope of Analysis for a query?6.What is a Scope of Analysis for a query?Answer:The scope of analysis for a query is extra levels of data in an objects hierarchy that you can retrieve from the database to give more detailed data returned by each of the objects.This extra data does not appear in the initial document results,but it remains available in the data cube,or data provider,so you can pull this data into the report to allow you to access more detail at any time.SAPPHIRE 2008 OR 4238/Page 9议 程n复习WebI报表设计基础课程n高级报表查询技术n使用计算上下文n利用字符和时间函数创建公式n使用IF逻辑n高级报表展现技术n使用超链接n实践练习,测验实践练习,测验Web Intelligence组合查询 SAP 2008/Page 11n使用两个查询n使用集合函数对结果进行合并,作为WebI报表的数据源Web Intelligence合并查询的优缺点优点优点n逻辑更清晰n可以实现一次查询无法完成的功能缺点缺点n对性能有影响Web Intelligence查询过滤器 子查询 SAP 2008/Page 13n一个过滤的操作数事先未知,依赖于另一个过滤n假设场景:销售经理需要知道大于Chicago 33rd仓库的销售额的那些仓库,并且列车仓库名和它们的销售额?Web Intelligence使用多个查询 SAP 2008/Page 14一个WebI文档可以基于多个查询(数据源),可以有多个块n一个查询投射到多个块n基于一个universe的多个查询n基于不同universe的多个查询Web Intelligence使用多个查询 SAP 2008/Page 15n一个数据块使用多个查询的数据时,得到的数据不准确n融合数据以解决问题Web Intelligence合并多数据源的数据Web Intelligence数据融合:维度的融合 SAP 2008/Page 17议 程n复习WebI报表设计基础课程n高级报表查询技术n使用计算上下文n利用字符和时间函数创建公式n使用IF逻辑n高级报表展现技术n使用超链接n实践练习,测验实践练习,测验 SAPPHIRE 2008 OR 4238/Page 19Web Intelligence计算上下文概念 SAPPHIRE 2008 OR 4238/Page 20States best year amount=max(Sales revenue)Web Intelligence输入计算上下文输入上下文直接包含在计算公式中的维度对象决定计算聚合的层次 SAPPHIRE 2008 OR 4238/Page 21States best year amount=max(Sales revenue In(Year;State)Web Intelligence输入计算上下文输入上下文直接包含在计算公式中的维度对象决定计算聚合的层次 SAPPHIRE 2008 OR 4238/Page 22Web Intelligence输入计算上下文 SAPPHIRE 2008 OR 4238/Page 23=Average(Sales revenue)=Average(Sales revenue)In BlockWeb Intelligence输出计算上下文输出上下文写在计算公式之外从计算好的结果中选择 SAPPHIRE 2008 OR 4238/Page 24Web Intelligence输出计算上下文议 程n复习WebI报表设计基础课程n高级报表查询技术n使用计算上下文n利用字符和时间函数创建公式n使用IF逻辑n高级报表展现技术n使用超链接n实践练习,测验实践练习,测验Web Intelligence变量 SAP 2008/Page 26n字符串函数nReplace-used to replace a specified string with another string.nRight-used to extract a given number of characters from the right.nLeft-used to extract a given number of characters from the left.nSubStr-used to extract a string of variable length and position.nLength-used to identify the length of a string.nPos-used to identify the position of a character in a string.nMatch-used to determine whether a character string matches a particular pattern.n可以使用通配符n?任意一个字符n*任意多个字符Web Intelligence变量 SAP 2008/Page 27n日期函数nToDate:changes the data type of a value to datenCurrentDate:gives the date todaynDaysBetween:calculates the number of days between two dates lace-used to replace a specified string with another stringnLastExecutionDate(string data_provider)nFormatDate(LastExecutionDate();Mmmm dd,yyyy)议 程n复习WebI报表设计基础课程n高级报表查询技术n使用计算上下文n利用字符和时间函数创建公式n使用IF逻辑n高级报表展现技术n使用超链接n实践练习,测验实践练习,测验Web IntelligenceIf逻辑 SAP 2008/Page 29If(条件;条件为真表达式;条件为假表达式)例子:=If(Quarter InList(Q1;Q2);Years First Half;Years Second Half)=IfQuarter InList(Q1;Q2)Then Years First Half Else Years Second HalfWeb IntelligenceIf逻辑 SAP 2008/Page 30应用场景:分组n=IfQuarter InList(Q1;Q2)Then Years First Half Else Years Second HalfWeb IntelligenceIf逻辑 SAP 2008/Page 31应用场景:基于条件的计算n=IfState=California Then Sales revenue*1.05 ElseIf State InList(DC;Florida;Illinois;New York;Texas)Then Sales revenue*1.15议 程n复习WebI报表设计基础课程n高级报表查询技术n使用计算上下文n利用字符和时间函数创建公式n使用IF逻辑n其他报表展现技术n使用超链接n实践练习,测验实践练习,测验Web IntelligenceMatch()函数 SAP 2008/Page 33=If Match(Store name;*Sundance)Then Sundance ElseIf Match(Store name;*Magnolia)Then Magnolia Else Un-BrandedWeb IntelligenceRunning聚合函数 SAP 2008/Page 34RunningSum,RunningAverage,RunningCount,RunningMin=RunningSum(Sales revenue)Web IntelligenceNoFilter SAP 2008/Page 35n覆盖报表使用的过滤或排序n可用于计算未分类部分的值=Sum(Sales revenue)=NoFilter(Sum(Sales revenue)-Sum(Sales revenue)=NoFilter(Sum(Sales revenue)议 程n复习WebI报表设计基础课程n高级报表查询技术n使用计算上下文n利用字符和时间函数创建公式n使用IF逻辑n高级报表展现技术n使用超链接n实践练习,测验实践练习,测验Web Intelligence超链接 SAP 2008/Page 37n给数据加上超级链接n将当前数据作为超级链接的参数n使用opendoc连接到另一个文档=a href=+http:/:8080/OpenDocument/opendoc/openDocument.jsp?+&sType=wid+&sDocName=Detailed+Sales+Report+&lsSEnter+State:=+Replace(State;%20)+State+“http:/:/:8080/OpenDocument/opendoc/openDocument.jsp?iDocID=1234议 程n复习WebI报表设计基础课程n高级报表查询技术n使用计算上下文n利用字符和时间函数创建公式n使用IF逻辑n高级报表展现技术n使用超链接n实践练习,测验测验1 SAPPHIRE 2008 OR 4238/Page 39n使用eFasion的示例Universe,根据如下的维度和计量,创建如下格式的报表:n目的:练习交叉表,报表拆分和函数的使用,报表的格式化 SAPPHIRE 2008 OR 4238/Page 40测验2n使用eFasion的示例Universe,根据如下的维度和计量,创建如下格式的报表:n目的:练习报表警报的 高亮显示 SAPPHIRE 2008 OR 4238/Page 41测验3n使用eFasion的示例Universe,根据如下的维度和计量,创建如下格式的报表:n目的:练习报表的表与图的组合使用,报表节以及基于节的汇总 SAPPHIRE 2008 OR 4238/Page 42测验4n使用eFasion的示例Universe,根据如下的维度和计量,创建如下格式的报表:nDocumentAuthor()函数以显示作者nUserResponse()以显示报表用户输入的报表过滤参数n变量Variable PLUS=20%的的Quantity Soldn变量变量variable TOTAL=Quantity Sold与与PLUS变量之和n目的:练习表头数据的显示,以及公式变量的使用测验5In a single document,build 2 queries using the following objects:Store name and Sales revenue(eFashion universe in root folder)Store name and Quantity sold (a Excel data from local machine)Then try to merge the dimension of store name,to make the data from the two datasources into one report.SAPPHIRE 2008 OR 4238/Page 43测验6 SAPPHIRE 2008 OR 4238/Page 44n使用eFasion的示例Universe,根据如下的维度和计量,创建如下格式的报表:n目的:练习使用逐行汇总,已经设定报表的计算顺序。测验7 SAPPHIRE 2008 OR 4238/Page 45n使用eFasion的示例Universe,根据如下的维度和计量,创建如下格式的报表:n=IfSales revenue7500000 Then Top Performers ElseIfSales revenueBetween(2000000;7500000)Then Average Performers ElseIfSalesrevenue2000000 Then Low Performers“n目的:练习IF逻辑的使用感感 谢谢Q&A更多信息更多信息SAP SAP 网页网页:SAP 开发者网络(SDN): SDN BusinessObjects论坛:http:/ Help:http:/ BusinessObjectsSAP BusinessObjects 社区(BOC):http:/ TechEd 2009SAP TechEd 2009 上海站上海站 只提供部分讲座只提供部分讲座 欢迎订阅欢迎订阅 Virtual TechEdcVirtual TechEdc SAP 2007/Page 48我们的共同努力铸就项目的成功!