Saiku_学习_01_saiku安装与运行
一、下载saiku
1.下载地址
官网:https://community.meteorite.bi/
2.解压后文件结构
3.ROOT和saiku
在tomcat/webapp 下有两个web应用,是与saiku相关的。
将环境变量中的CATALINA_HOME设置为这里的tomcat,
然后运行saiku-server下的start-saiku.bat
访问 localhost:8080/upload.html ,可以看到一个让你上传license的页面,如下图:
4.获取license文件
前往 https://licensing.meteorite.bi/login ,注册账号并进行登录。
创建公司,然后创建license,在下载license文件
5.上传license
前往 localhost:8080/upload.html ,将 4 中下载的license文件上传。
上传时需要的账号:admin ,admin
6.登录saiku
前往 localhost:8080 ,输入admin,admin ,即可登录saiku 系统。
二、创建数据库与数据库驱动
1.创建数据库
(1)新建一个数据库,数据库名称为:sakiu_demo(原谅我创建数据库的时候粗心把saiku打成sakiu了)。
(2)新建一个查询,运行以下sql语句,来建表和导入数据
建表和导入数据的sql语句太大上传不了,请移步:saiku安装部署资源
2.添加数据库驱动
下载相应的数据库驱动放到 saiku-server/tomcat/webapps/saiku/WEB-INF/lib 目录下
三、添加 schema
1.新建 sales_mondrian_schema.xml
(1)在 saiku-server\tomcat\webapps\saiku\WEB-INF\classes 路径下新建saiku-datasources文件夹
(2)在 saiku-datasources文件夹下新建sales_mondrian_schema.xml,文件内容如下
<Schema name="Sauce Dallas schema"><Cube name="Sales" visible="true" description="sales cube or Sauce Dallas" cache="true" enabled="true"><Table name="fact_sales"></Table><Dimension type="StandardDimension" visible="true" foreignKey="customer_id" highCardinality="false" name="customers dimension" caption="customers"><Hierarchy name="h_region" visible="true" hasAll="true" allMemberName="All" allLevelName="all levels" primaryKey="customer_id" caption="region" description="regions hierarchy"><Table name="dim_customers" alias="customers dimension"></Table><Level name="continent" visible="true" column="continent" type="String" uniqueMembers="false" levelType="Regular" hideMemberIf="Never" caption="continent"></Level><Level name="country" visible="true" column="country" type="String" uniqueMembers="false" levelType="Regular" hideMemberIf="Never" caption="country"></Level><Level name="state" visible="true" column="state" type="String" uniqueMembers="false" levelType="Regular" hideMemberIf="Never" caption="state"></Level><Level name="city" visible="true" column="city" type="String" uniqueMembers="false" levelType="Regular" hideMemberIf="Never" caption="city"></Level></Hierarchy></Dimension><Dimension type="StandardDimension" visible="true" foreignKey="product_code" highCardinality="false" name="product" caption="product"><Hierarchy name="h_product" visible="true" hasAll="true" allMemberName="all products" allLevelName="all levels" primaryKey="product_code" caption="products" description="products hierarchy"><Table name="dim_products" alias="products dimension"></Table><Level name="product type" visible="true" column="product_type" type="String" uniqueMembers="false" levelType="Regular" hideMemberIf="Never" caption="product type" description="product types"></Level><Level name="product code" visible="true" column="product_code" type="String" uniqueMembers="false" levelType="Regular" hideMemberIf="Never" caption="product code" description="product code"></Level></Hierarchy></Dimension><Dimension type="TimeDimension" visible="true" foreignKey="date_id" highCardinality="false" name="time dimension" caption="time"><Hierarchy name="h_month" visible="true" hasAll="true" allMemberName="all years" allLevelName="all" primaryKey="date_id" caption="months hierarchy" description="months hierarchy"><Table name="dim_time" alias="time dimension"></Table><Level name="year" visible="true" column="year" type="String" uniqueMembers="false" levelType="TimeYears" hideMemberIf="Never" caption="year"></Level><Level name="quarter" visible="true" column="quarter" type="String" uniqueMembers="false" levelType="TimeQuarters" hideMemberIf="Never" caption="quarter"></Level><Level name="month" visible="true" column="month_number" nameColumn="month_long_name" type="Integer" uniqueMembers="true" levelType="TimeMonths" hideMemberIf="Never" caption="month"></Level></Hierarchy></Dimension><Measure name="sales amount" column="amount" datatype="Numeric" formatString="#,### $" aggregator="sum" visible="true"></Measure><Measure name="quantity" column="quantity" datatype="Integer" aggregator="sum" visible="true"></Measure></Cube> </Schema>
View Code
2.添加 schema
按下图步骤,将sales_mondrian_schema.xml上传,Schema Name 随意取
四、配置数据源
1.配置数据源
type=OLAP name=sakiu_demo driver=mondrian.olap4j.MondrianOlap4jDriver location=jdbc:mondrian:Jdbc=jdbc:mysql://localhost:3306/sakiu_demo;Catalog=res:saiku-datasources/sales_mondrian_schema.xml;JdbcDrivers=com.mysql.jdbc.Driver; username=root password=123 security.enabled=false
2.配置说明
type=OLAP : 指定一个 OLAP 引擎.没有见过非OLAP的属性值。 name : 给你的数据源命名,随意命名。 driver : 指定 Mondrian driver(将二维关系表转化为多维度表的驱动).没有见过其他的属性值。 location : 这个属性有几个部分组成,使用分号分隔。jdbc:mondrian:Jdbc=jdbc:mysql://localhost:3306/sakiu_demo; 指定数据库对应jdbc url,需要修改主机和对应的数据库名称。这里的主机是localhost,对应数据库是sakiu_demo Catalog=res:saiku-datasources/sales_mondrian_schema.xml 指定mondrian schema文件。res表明是文件的路径,这里是从saiku webapp目录开始; JdbcDrivers=com.mysql.jdbc.Driver 指明java 类文件作为数据库连接驱动。username : 连接数据库的用户名password : 连接数据库的密码
3.pgsql
type=OLAP name=postgres driver=mondrian.olap4j.MondrianOlap4jDriver location=jdbc:mondrian:Jdbc=jdbc:postgresql://192.168.11.197:5432/postgres;Catalog=res:saiku-datasources/bgt_amount.xml;JdbcDrivers=org.postgresql.Driver; username=postgres password=postgres security.enabled=false
五、重新登录
需要登录项目,才能在新建查询选择刚刚添加的数据源对应的cube。先注销,再登录。如下图
至此就可以很方便的对数据库中数据进行多维分析了
六、参考资料
精选:
1.saiku安装方法总结
其他:
1.[saiku] 在 Tomcat 下部署 saiku
2.saiku安装
3.在Tomcat上安装部署SAIKU
Saiku_学习_01_saiku安装与运行相关推荐
- Nexus学习笔记 -- 安装到运行
2019独角兽企业重金招聘Python工程师标准>>> 1.下载Nexus :http://www.sonatype.org/nexus/ Nexus Repository ...
- OMNeT学习之OMNeT安装与运行
OMNeT学习之OMNeT安装与运行 前言 本文原创,创作不易,转载请注明!!! 本人为OMNet初学者,如有错误,请不吝请教! 最近学WSN(无线传感器网络),做传感器实验,老师强调了仿真平台Mat ...
- access窗体独立运行_由浅入深学习网络设备模拟器HCL 第一篇 安装与运行
小伙伴们在学习计算机网络知识时往往并没有机会接触交换机.路由器等网络设备,这种情况下仅仅通过书本知识的学习很难提高实际操作能力,别着急,网络设备商早已想到这个问题,推出了网络设备模拟软件,高度还原真实 ...
- 学习安装java运行环境
提示:学习安装java运行环境 文章目录 安装JDK 一.配置windows环境变量. 1.配置环境变量 2. 配置path 3.测试JDK是否安装成功 总结 安装JDK 提示:由于JDK8为大部份公 ...
- onlyoffice学习记录-安装与Demo运行
onlyoffice 安装与运行 公司项目需要导入自定义表单然后分发给不同人去填写,然后再搜集汇总,于是便研究了在线协作文档开源框架onlyoffice.发现网络上这个并没有很详细的技术文档,于是对照 ...
- LOAM学习-安装与运行
LOAM-安装与运行 引言 LOAM安装 LOAM运行 结语 引言 由于最近想学习SLAM,发现LOAM是较为经典的入门算法. 于是就开始了LOAM的学习. LOAM安装 LOAM的安装真的是一言难尽 ...
- linux安装并运行kafka有三步,kafka学习
linux安装并运行kafka有三步 1:安装jdk(自行搜索linux安装jdk) 环境变量vi /etc/profile export JAVA_HOME=HOME/jdkexportCLASSP ...
- windows 不安装jdk 运行 jar_新手必看。关于Python3——windows安装与运行(详细版)...
Python3 可应用于多平台 Windows.Linux 和 Mac OS X. windows就是我们现在常用的电脑系统 linux系统,程序员的天堂. mac OS X ,也就是苹果系统啦 Py ...
- Python3入门笔记(1) —— windows安装与运行
Python3入门笔记(1) -- windows安装与运行 Python的设计哲学是"优雅"."明确"."简单".这也是我喜欢Python ...
最新文章
- [安全防护]StackGuard和StackShield
- oracle 11 导入到 10,oracle11g导入到10g
- SSH初体验系列--Hibernate--1--环境配置及demo
- 怎么升级计算机硬盘,研究僧 篇一:记一次老电脑的升级之路
- 应急照明市电检测_应急照明供电及接线(图析)
- python自定义模块的使用_python自定义模块使用说明
- python中使用函数的优点_在python中使用自定义初始化函数而不是`__init__`的好处...
- 16进制发送 mqtt客户端调试工具_MQTT客户端调试工具(MQTT Simulate Device)
- origin做相关性分析图_Origin教程第六章 使用Origin进行数据分析
- 阿里云函数计算(一)
- Docker监控远程服务器
- 7.项目成本管理+信息系统项目管理+野马合集
- 怎么查看qq登陆记录
- matlab画简单长方形,matlab在图像中画长方形(框)
- [益智]:快速估算题:估算电视塔的重量......
- 新书上市 | 《Java性能优化实践》,众多业内大佬推荐阅读
- 黑龙江计算机单招学校,黑龙江信息技术职业学院单招(2020年单独招生计划)...
- Mapreduce学习指导及疑难解惑汇总
- 使用进销存财务软件有哪些好处?进销存财务软件该如何选?
- 维也纳国际酒店+丽柏酒店首个同物业双品牌项目成功加盟,中高端酒店品牌联动浮现新模式