相同的 MDX,jasperreports 4.0、Schema Workbench 和 Jasperserver 3.7.1 上的结果不同
我正在使用 jasperserver 3.7.1,本周我升级到 jasperreports 4.0 一切都很顺利,直到我意识到 jasperreports 没有显示今年(2011 年)的任何数据。 这很奇怪,因为如果我进入 Schema workbench 或 jasperserver 3.7.1,我的 MDX 查询会给出预期的结果。 2011 年的每个 MDX 查询都显示空结果。
这是一个 MDX 简单示例:
select {[Measures].[Ocorrencias]} ON COLUMNS,
{ [Time.month].[2011].[Q1].Children } ON ROWS
from [Ocorrencias]
这是我的 shcema 的时间维度:
<Dimension type="TimeDimension" name="Time">
<Hierarchy name="month" hasAll="true" primaryKey="idtempo">
<Table name="timeid">
</Table>
<Level name="Ano" column="ano" type="Numeric" uniqueMembers="true" levelType="TimeYears" hideMemberIf="Never">
</Level>
<Level name="Trimestre" column="idtrimestre" nameColumn="trimestre" type="Numeric" uniqueMembers="false" levelType="TimeQuarters" hideMemberIf="Never">
</Level>
<Level name="Mes" column="idmes" nameColumn="mes" type="Numeric" uniqueMembers="false" levelType="TimeMonths" hideMemberIf="Never">
</Level>
</Hierarchy>
<Hierarchy name="week" hasAll="true" primaryKey="idtempo">
<Table name="timeid">
</Table>
<Level name="Ano" column="ano" type="Numeric" uniqueMembers="true" levelType="TimeYears" hideMemberIf="Never">
</Level>
<Level name="Semana" column="semana_ano" type="Numeric" uniqueMembers="false" levelType="TimeWeeks" hideMemberIf="Never">
</Level>
<Level name="Dia" column="dia_mes" nameColumn="dia_nome" type="Numeric" uniqueMembers="false" levelType="TimeDays" hideMemberIf="Never">
</Level>
</Hierarchy>
</Dimension>
这是整个架构文件。
我已经完成了全新安装,但问题仍然存在。
如果您可以帮助我或指出任何方向,我真的很感谢您的帮助。 谢谢
I'm using jasperserver 3.7.1 and this week i upgraded to jasperreports 4.0
Everything went fine until i realize that jasperreports does not show any data for this year (2011).
This is strange because if i went to Schema workbench or jasperserver 3.7.1 my MDX query give the expected result.
Every MDX query for the year 2011 is showing empty results.
This is an MDX simple example:
select {[Measures].[Ocorrencias]} ON COLUMNS,
{ [Time.month].[2011].[Q1].Children } ON ROWS
from [Ocorrencias]
This is the time dimension of my shcema:
<Dimension type="TimeDimension" name="Time">
<Hierarchy name="month" hasAll="true" primaryKey="idtempo">
<Table name="timeid">
</Table>
<Level name="Ano" column="ano" type="Numeric" uniqueMembers="true" levelType="TimeYears" hideMemberIf="Never">
</Level>
<Level name="Trimestre" column="idtrimestre" nameColumn="trimestre" type="Numeric" uniqueMembers="false" levelType="TimeQuarters" hideMemberIf="Never">
</Level>
<Level name="Mes" column="idmes" nameColumn="mes" type="Numeric" uniqueMembers="false" levelType="TimeMonths" hideMemberIf="Never">
</Level>
</Hierarchy>
<Hierarchy name="week" hasAll="true" primaryKey="idtempo">
<Table name="timeid">
</Table>
<Level name="Ano" column="ano" type="Numeric" uniqueMembers="true" levelType="TimeYears" hideMemberIf="Never">
</Level>
<Level name="Semana" column="semana_ano" type="Numeric" uniqueMembers="false" levelType="TimeWeeks" hideMemberIf="Never">
</Level>
<Level name="Dia" column="dia_mes" nameColumn="dia_nome" type="Numeric" uniqueMembers="false" levelType="TimeDays" hideMemberIf="Never">
</Level>
</Hierarchy>
</Dimension>
This is the whole schema file.
I already have done a clean installation and the problem persists.
If you can help me or point in any direction, i really apreciate your help.
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我发现了问题。
我在这里发布这个答案只是为了帮助其他犯同样错误的人。
问题是我的时间数据库表在列日上有一些错误,我之前没有注意到。
由于未知的原因,老蒙德里安犯了这个错误。
I found the problem.
I only post here this answer to help other people who commit the same mistake.
The problem is that my time database table have some mistakes on the columnn days, that i didn't notice before.
For unkown reason the old mondrian work with that mistake.