数据源设置:
数据处理逻辑:
--I_GBGradeID SELECT * FROM T_NPick_PkgMov WHERE I_GBGradeID NOT IN ( SELECT I_GBGradeID FROM T_GBGradeCode ) DELETE FROM T_NPick_PkgMov WHERE I_GBGradeID NOT IN ( SELECT I_GBGradeID FROM T_GBGradeCode ) --V_CustomerID SELECT * FROM T_NPick_PkgMov WHERE V_CustomerID NOT IN ( SELECT C_CustCode FROM T_CustomInfo ) ALTER TABLE T_NPick_PkgMov ALTER COLUMN V_CustomerID VARCHAR(5) NOT NULL --新增业务日期BusinessDate字段 ALTER TABLE T_NPick_PkgMov ADD BusinessDate INT NULL --将datetime转为int UPDATE T_NPick_PkgMov SET BusinessDate = CAST(REPLACE(CONVERT(CHAR(10), D_Time, 120), ‘-‘, ‘‘) AS INT)
主要指标:
N_Weight重量_合计
I_Piece 件数_合计
需要抽取的维度表:
序号 |
表名 |
说明 |
备注 |
1 |
T_GBGradeCode |
烟叶级别 |
|
2 |
T_Distinction |
烟叶等级 |
|
3 |
T_Origin |
产地 |
|
4 |
T_PurchaseType |
收购类型 |
|
5 |
T_TLProcType |
加工类型 |
|
6 |
T_CustomInfo |
客户 |
需要抽取的事实表:
序号 |
表名 |
说明 |
备注 |
1 |
T_NPick_PkgMov |
挑选产出 |
V_CycleNode 01 挑选产出 |
项目结构:
浏览效果:
客户端:
时间: 2024-10-05 05:31:38