Pentaho的CDE显示交叉表格
原来以为Table Component只能显示二维表格,但是在《Learning Pentaho CTools(PACKT,2016).pdf》看到交叉表(第6单元)
.
MDX:
WITH MEMBER [Measures].[Trend] as IIF(ISEMPTY(([Time].CURRENTMEMBER.lag(1), [Measures].[Sales])) OR [Measures].[Sales]=0, 0, ([Measures].[Sales]- ([Time].CURRENTMEMBER.lag(1), [Measures].[Sales])) /[Measures]. [Sales])+0 MEMBER [Measures].[Sales ($)] as [Measures].[Sales]+0 MEMBER [Measures].[Qt] as [Measures].[Quantity]+0 SELECT NON EMPTY CrossJoin({[Markets].[Territory].Members}, {[Measures].[Qt], [Measures].[Sales ($)], [Measures]. [Trend]}) ON COLUMNS, NON EMPTY {[Product].[Product].Members} ON ROWS FROM [SteelWheelsSales] Where [Time].[2004]
Table Component
.
Post Execution
function f() { var cells = $( "#" + this.htmlObject + " thead th" ); var level = "1"; cells.each(function(i, v) { if( i > 0 ) { //skip the first cell of each row var cell = $( v ); var originalText = cell.text(); var originalTextParts = originalText.split( "/" ); // cell.text( originalTextParts[1] ); //write the second part (the mobile company in your case) if(originalTextParts.length>1) { level = originalTextParts.length-1; } } }); var idx; for (idx = 0; idx < level; idx++) { var newHeaderRow1 = "<tr><th></th>"; var text='' var text_length=1 cells.each(function(i, v) { if( i > 0 ) { //skip the first cell of each row var cell = $( v ); var originalText = cell.text(); var originalTextParts = originalText.split( "/" ); // cell.text( originalTextParts[1] ); //write the second part (the mobile company in your case) if(originalTextParts.length==1) { newHeaderRow1+="<th></th>" } else if(originalTextParts.length>1) { if(text!=originalTextParts[idx]) { if(text === '') { text=originalTextParts[idx] } else { newHeaderRow1+=("<th valign='middle' align='center' colspan='"+text_length+"'>"+text+"</th>") text_length=1 text=originalTextParts[idx] } } else { text_length++; if((cells.length-1) == i) { newHeaderRow1+=("<th valign='middle' align='center' colspan='"+text_length+"'>"+text+"</th>") text_length=1 text=originalTextParts[idx] } } } } }); newHeaderRow1+="</tr>" $( "#" + this.htmlObject + " thead" ).prepend( newHeaderRow1 ); } cells.each(function(i, v) { if( i > 0 ) { //skip the first cell of each row var cell = $( v ); var originalText = cell.text(); var originalTextParts = originalText.split( "/" ); cell.text( originalTextParts[1] ); //write the second part (the mobile company in your case) } }); var newHeaderRow = "<tr><th></th><th colspan='4'>Latenza Media</th><th colspan='4'>Through. Download Medio</th></tr>"; // $( "#" + this.htmlObject + " thead" ).prepend( newHeaderRow ); //add some style... $( "#" + this.htmlObject + " thead th" ).css( "border", "1px solid #DEDEDE" ).css( "background", "#F9F9F9" ); $( "#" + this.htmlObject + " thead th:eq(0)" ).css( "border", "0px solid #DEDEDE" ).css( "background", "#FFFFFF" ); //hide first cell }
.
相关推荐
Learning Pentaho CTools Color Images Learning Pentaho CTools Color Images pentaho数据可视化 CTools 套件学习 使用书籍
learning-pentaho-ctoolslearning-pentaho-ctoolslearning-pentaho-ctoolslearning-pentaho-ctoolslearning-pentaho-ctoolslearning-pentaho-ctoolslearning-pentaho-ctools
Being an introductory chapter Chapter 1, Getting Started with CTools andChapter 9: Pentaho App Builder, Chapter 10, Embed, Deploy, and Debugdoes not contain code files. Chapter 1, Getting Started ...
Pentaho and CTools are two of the fastest and most rapidly growing tools for practical solutions not found in any other tool available on the market. Using Pentaho allows you to build a complete ...
Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, ...
作为介绍性章节,第1章,CTools入门和第9章:Pentaho App Builder,第10章,嵌入,部署和调试不包含代码文件。 第1章“ CTools入门”简要介绍了CTools的历史。 它还将向您介绍该工具的用途,并教您安装社区工具...
1:Learning Pentaho CTools(PACKT,2016).pdf 2:Pentaho Data Integration Beginner's Guide, Second Edition.pdf 3:Packt.Pentaho for Big Data Analytics.2013.pdf 4:pentaho kettle solutions.pdf 5:[Packt ...
赠送jar包:pentaho-aggdesigner-algorithm-5.1.5-jhyde.jar; 赠送原API文档:pentaho-aggdesigner-algorithm-5.1.5-jhyde-javadoc.jar; 赠送源代码:pentaho-aggdesigner-algorithm-5.1.5-jhyde-sources.jar; ...
Pentaho Solutions Pentaho Solutions
[Packt Publishing] Pentaho 5.0 报表实例开发 初学者指南 (英文版) [Packt Publishing] Pentaho 5.0 Reporting by Example Beginner's Guide (E-Book) ☆ 图书概要:☆ Create high-quality, professional, ...
pentaho kettle中文开发手册
解决 Cannot resolve org.pentaho:pentaho-aggdesigner-algorithm:5.1.5-jhyde jar放入D根目录执行: 以下命令加入本地maven库 mvn install:install-file -DgroupId=org.pentaho -DartifactId=pentaho-aggdesigner-...
创建 Pentaho Solutions 中文
pentaho4.8版本的汉化总结 其中包含绝大部分的汉化
Pentaho Data Integration(原Kettle)和 Data Reporting工具最新版9.0.0.2.530百度云下载地址 ETL工具及报表展示工具
Pentaho Reporting(2014) 资源挺多的
Pentaho笔记 3 2 使用MySQL作为Pentaho默认数据库 4 2.1 创建数据库 4 2.2 配置Pentaho 4 1配置Pentaho使用FoodMart数据 6 1.1注册数据源 6 1.2定义多维数据schema 7 1.3注册schema 7 1.4配置Pentaho使用filesystem-...
Pentaho Solutions Business Intelligence and Data Warehousing with Pentaho and MySQL
org / pentaho / pentaho-aggdesigner-algorithm / 5.1.5-jhyde / pentaho-aggdesigner-algorithm-5.1.5-jhyde.jar,解决maven引入hive的jar包时依赖报错Could not find artifact org.pentaho:pentaho-aggdesigner-...
pentaho初学者,整理了一些使用的过程和配置