空间mdx日期聚合功能不适用于日期01/01/2014

时间:2014-11-28 14:42:49

标签: analytics mdx mondrian olap4j data-cube

这是我发出错误的mdx

`with member [Measures].[incident_type] as '[incident].CurrentMember.Properties("incident_type")'
  member [Measures].[incident_desc] as '[incident].CurrentMember.Properties("incident_desc")'
  member [Measures].[incident_class] as '[incident].CurrentMember.Properties("incident_class")'
  member [Measures].[incident_image] as '[incident].CurrentMember.Properties("incident_image")'
  member [Measures].[modus_operandi] as '[incident].CurrentMember.Properties("modus_operandi")'
  member [Measures].[fir_status] as '[incident].CurrentMember.Properties("fir_status")'
  member [Measures].[fir_id] as '[incident].CurrentMember.Properties("fir_id")'
  member [Measures].[date_start_time] as '[incident].CurrentMember.Properties("date_start_time")'
  member [Measures].[the_geom] as '[incident].CurrentMember.Properties("the_geom")'
  member [Measures].[date_end_time] as '[incident].CurrentMember.Properties("date_end_time")'
   member [time].[newtime] as 'Aggregate({([time].[2012].[12].[19] : [time].[2012].[12].[31]),([time].[2013]),([time].[2014].[1].[1] : [time].[2014].[1].[8])})'
select {[Measures].[incident_type], [Measures].[incident_desc], [Measures].[incident_class], [Measures].[incident_image], [Measures].[modus_operandi], [Measures].[fir_status], [Measures].[fir_id],  [Measures].[the_geom], [Measures].[date_start_time] ,[Measures].[date_end_time] ,  [Measures].[incident_count]} ON COLUMNS,NON EMPTY Filter([incident].[incident_id].Members, ST_Contains([district].[district_id].[13221].Properties("the_geom"), [incident].CurrentMember.Properties("the_geom"))) ON ROWS  from [pin_mapping]  where ([time].[newtime])`

我正在geomondrian workbench上测试它,它显示如下错误:

  

`Mondrian错误:无法使用成员解析查询'   [措施]。[incident_type] as   '[事件] .CurrentMember.Properties(“incident_type”)'成员   [措施]。[incident_desc] as   '[事件] .CurrentMember.Properties(“incident_desc”)'成员   [措施]。[incident_class] as   '[事件] .CurrentMember.Properties(“incident_class”)'成员   [测量]。[incident_image] as   '[事件] .CurrentMember.Properties(“incident_image”)'成员   [措施]。[modus_operandi] as   '[事件] .CurrentMember.Properties(“modus_operandi”)'成员   [措施]。[fir_status] as   '[事件] .CurrentMember.Properties(“fir_status”)'成员   [测量]。[fir_id] as'[incident] .CurrentMember.Properties(“fir_id”)'   成员[Measures]。[date_start_time] as   '[事件] .CurrentMember.Properties(“date_start_time”)'成员   [措施]。[the_geom] as   '[事件] .CurrentMember.Properties(“the_geom”)'成员   [测量]。[date_end_time] as   '[事件] .CurrentMember.Properties(“date_end_time”)'成员   [时间]。[newtime]为'Aggregate({([time]。[2012]。[12]。[19]:   [时间]。[2012]。[12]。[31]),([时间]。[2013]),([时间]。[2014]。[1]。[1]:   [时间]。[2014]。[1]。[8])})'select {[Measures]。[incident_type],   [措施]。[incident_desc],[措施]。[incident_class],   [Measures]。[incident_image],[Measures]。[modus_operandi],   [测量]。[fir_status],[测量]。[fir_id],[测量]。[the_geom],   [Measures]。[date_start_time],[Measures]。[date_end_time],   [措施]。[incident_count]} ON COLUMNS,NON EMPTY   过滤器([事件] [incident_id] .Members,   ST_Contains([地区]。[district_id]。[13221]的.properties( “the_geom”),   [事件] .CurrentMember.Properties(“the_geom”)))ON ROWS来自   [pin_mapping]其中([时间]。[newtime])'

     

`Mondrian错误:使用成员解析MDX语句时出错   [措施]。[incident_type] as   '[事件] .CurrentMember.Properties(“incident_type”)'成员   [措施]。[incident_desc] as   '[事件] .CurrentMember.Properties(“incident_desc”)'成员   [措施]。[incident_class] as   '[事件] .CurrentMember.Properties(“incident_class”)'成员   [测量]。[incident_image] as   '[事件] .CurrentMember.Properties(“incident_image”)'成员   [措施]。[modus_operandi] as   '[事件] .CurrentMember.Properties(“modus_operandi”)'成员   [措施]。[fir_status] as   '[事件] .CurrentMember.Properties(“fir_status”)'成员   [测量]。[fir_id] as'[incident] .CurrentMember.Properties(“fir_id”)'   成员[Measures]。[date_start_time] as   '[事件] .CurrentMember.Properties(“date_start_time”)'成员   [措施]。[the_geom] as   '[事件] .CurrentMember.Properties(“the_geom”)'成员   [测量]。[date_end_time] as   '[事件] .CurrentMember.Properties(“date_end_time”)'成员   [时间]。[newtime]为'Aggregate({([time]。[2012]。[12]。[19]:   [时间]。[2012]。[12]。[31]),([时间]。[2013]),([时间]。[2014]。[1]。[1]:   [时间]。[2014]。[1]。[8])})'select {[Measures]。[incident_type],   [措施]。[incident_desc],[措施]。[incident_class],   [Measures]。[incident_image],[Measures]。[modus_operandi],   [测量]。[fir_status],[测量]。[fir_id],[测量]。[the_geom],   [Measures]。[date_start_time],[Measures]。[date_end_time],   [措施]。[incident_count]} ON COLUMNS,NON EMPTY   过滤器([事件] [incident_id] .Members,   ST_Contains([地区]。[district_id]。[13221]的.properties( “the_geom”),   [事件] .CurrentMember.Properties(“the_geom”)))ON ROWS来自   [pin_mapping]其中([时间]。[newtime])'

蒙德里安错误:MDX对象'[时间]。[2014]。[1]。[1]'找不到立方体'pin_mapping']`

出现此错误的原因是什么?

1 个答案:

答案 0 :(得分:0)

尝试将[time].[2014].[1].[1]更改为多维数据集中存在的成员。你还得到同样的错误吗?

如果您使用:执行范围并且左侧或右侧成员不存在,则引擎会将此成员评估为null