首页 \ 问答 \ 如何在Pentaho Mondrian模式XML中使用公式(how to use formula in Pentaho Mondrian schema XML)

如何在Pentaho Mondrian模式XML中使用公式(how to use formula in Pentaho Mondrian schema XML)

我正在研究ReportServer中的Saiku报告。 我添加了一个Mondrian数据源。 现在我想在报告中添加两行以显示第三行中的Sum,我做了一些R&D并发现我们可以使用Cell格式化程序,它可以使用Formula来使用Schema XML中的列。 但我无法得到确切的消息来源。 以下是我从Mondrian文档中找到的来源:

<CalculatedMember name="name" dimension="dimension">
<Formula>
[Measures].[Unit Sales] * 2
</Formula>
<CellFormatter>
<Script language="JavaScript">
var s = value.toString();
while (s.length() < 20) {
s = "0" + s;
}
return s;
</Script>
</CellFormatter>
</Measure>

但这似乎是不正确的,这个块我想要使用公式标签并使用[Measures].[Unit Sales] * 2看起来对我有帮助。

任何人都可以帮我纠正这个标签。


I'm working on Saiku reports in ReportServer. I have added a Mondrian Data Source. Now i would like to add two Rows in the report to show a Sum in the 3rd row, i did some R&D and found that we can use Cell formatter that can use Formula to use columns from the Schema XML. But i'm unable to get is exact source. Here is the source i found from Mondrian Documentation:

<CalculatedMember name="name" dimension="dimension">
<Formula>
[Measures].[Unit Sales] * 2
</Formula>
<CellFormatter>
<Script language="JavaScript">
var s = value.toString();
while (s.length() < 20) {
s = "0" + s;
}
return s;
</Script>
</CellFormatter>
</Measure>

But this seems incorrect and this the block i want as its use Formula tag and using [Measures].[Unit Sales] * 2 that is looking helpful for me.

Can any one help me to correct this tag.


原文:https://stackoverflow.com/questions/41262634
更新时间:2022-05-18 17:05

最满意答案

不.POST不是幂等的,因为你无法访问Fastly(Firebase托管CDN提供商)清漆规则,你甚至无法“破解”实现它。


No. POST is not idempotent, and as you don't get the access to Fastly (Firebase Hosting CDN provider) varnish rules, you cannot even "hack" to achieve it.

相关问答

更多
  • 不.POST不是幂等的,因为你无法访问Fastly(Firebase托管CDN提供商)清漆规则,你甚至无法“破解”实现它。 No. POST is not idempotent, and as you don't get the access to Fastly (Firebase Hosting CDN provider) varnish rules, you cannot even "hack" to achieve it.
  • 如果仔细比较你的JSON和文档中的JSON,你会在数据之前和之后有一个额外的" 。这意味着你发布了一个大的字符串,而不是一个JSON对象。 解决方法是从开始和结束删除多余的双引号。 这也意味着你不再需要转义JSON中的双引号: '{"senderId":"CBPA9tdrNyc1Y3AxSb8rkZjDJxh2","senderName":"John","text":"Hello its me"}' 如果您用于发布的工具尝试将JSON解析为单个字符串,则需要单引号。 如果没有(提示:hurl.it没有), ...
  • 不要使用POST。 根据文件 : 要完成JavaScript push()方法(请参阅数据列表)的等价物,您可以发出POST请求。 你不想在这里推。 推送操作会创建一个新的随机推送ID并使其成为您提供的数据的关键。 如果你已经知道你想要设置的位置(它看起来像你已经有一个已知的推送ID),只需使用PUT来设置该位置的数据。 Don't use POST. According to the documentation: To accomplish the equivalent of the JavaScript ...
  • 这是预期的和正常的行为。 Firebase数据库客户端通过Web套接字与其服务器通信。 这种联系是一个持久的联系。 调用本质上从来没有“完成”,因为可能会有更多的数据来自数据库。 这就是为什么你在你的开发工具中看到状态101和Pending 。 This is expected and normal behavior. The Firebase Database client communicates with its server over a web socket. This connection is ...
  • 我究竟做错了什么? 您在console.log()中包装异步调用,期望$.post() .responseText或.responseJSON ,或$.post()的回调函数的参数在console上记录异步调用。 console.log()不等待异步调用完成或完成。 console.log()将记录返回的$.post()的jQuery promise对象 但是,当我检查控制台时,我发现它是一个类型Object {readyState: "1"} 不是.responseText或jxXHR对象的jxXHR属性 ...
  • 目前,Spark计划无法从另一个HTTP云功能调用HTTP云功能。 您必须升级到Blaze计划。 对于一个项目的函数来说,通过HTTP调用其他函数大多没有意义。 如果您只是将逻辑抽象为所有端点可以共享的单个函数或模块,则可以在所有函数之间共享项目中的所有代码。 It's currently not possible on the Spark plan to invoke an HTTP Cloud Function from another HTTP Cloud Function. You will hav ...
  • NSError *error; id obj= [NSJSONSerialization JSONObjectWithData:data options:0 error:&error]; if (!obj) { NSLog(@"JSON parse error: %@", error); } else { NSLog(@"obj= %@", obj); } NSError *error; id obj= [NSJSONS ...
  • 由于dataTaskWithRequest是异步的,因此该函数将在执行完成块之前dataTaskWithRequest您的return语句。 你应该做的是为你自己的帮助器方法设置一个完成块,或者将某种委托对象传递给该函数,以便你可以调用它上面的方法让它知道webservice回调的结果是什么。 以下是使用完成块的示例: class func hello(name: String, completion: (String? -> Void)){ let request = NSMutableURLR ...

相关文章

更多

最新问答

更多
  • 您如何使用git diff文件,并将其应用于同一存储库的副本的本地分支?(How do you take a git diff file, and apply it to a local branch that is a copy of the same repository?)
  • 将长浮点值剪切为2个小数点并复制到字符数组(Cut Long Float Value to 2 decimal points and copy to Character Array)
  • OctoberCMS侧边栏不呈现(OctoberCMS Sidebar not rendering)
  • 页面加载后对象是否有资格进行垃圾回收?(Are objects eligible for garbage collection after the page loads?)
  • codeigniter中的语言不能按预期工作(language in codeigniter doesn' t work as expected)
  • 在计算机拍照在哪里进入
  • 使用cin.get()从c ++中的输入流中丢弃不需要的字符(Using cin.get() to discard unwanted characters from the input stream in c++)
  • No for循环将在for循环中运行。(No for loop will run inside for loop. Testing for primes)
  • 单页应用程序:页面重新加载(Single Page Application: page reload)
  • 在循环中选择具有相似模式的列名称(Selecting Column Name With Similar Pattern in a Loop)
  • System.StackOverflow错误(System.StackOverflow error)
  • KnockoutJS未在嵌套模板上应用beforeRemove和afterAdd(KnockoutJS not applying beforeRemove and afterAdd on nested templates)
  • 散列包括方法和/或嵌套属性(Hash include methods and/or nested attributes)
  • android - 如何避免使用Samsung RFS文件系统延迟/冻结?(android - how to avoid lag/freezes with Samsung RFS filesystem?)
  • TensorFlow:基于索引列表创建新张量(TensorFlow: Create a new tensor based on list of indices)
  • 企业安全培训的各项内容
  • 错误:RPC失败;(error: RPC failed; curl transfer closed with outstanding read data remaining)
  • C#类名中允许哪些字符?(What characters are allowed in C# class name?)
  • NumPy:将int64值存储在np.array中并使用dtype float64并将其转换回整数是否安全?(NumPy: Is it safe to store an int64 value in an np.array with dtype float64 and later convert it back to integer?)
  • 注销后如何隐藏导航portlet?(How to hide navigation portlet after logout?)
  • 将多个行和可变行移动到列(moving multiple and variable rows to columns)
  • 提交表单时忽略基础href,而不使用Javascript(ignore base href when submitting form, without using Javascript)
  • 对setOnInfoWindowClickListener的意图(Intent on setOnInfoWindowClickListener)
  • Angular $资源不会改变方法(Angular $resource doesn't change method)
  • 在Angular 5中不是一个函数(is not a function in Angular 5)
  • 如何配置Composite C1以将.m和桌面作为同一站点提供服务(How to configure Composite C1 to serve .m and desktop as the same site)
  • 不适用:悬停在悬停时:在元素之前[复制](Don't apply :hover when hovering on :before element [duplicate])
  • 常见的python rpc和cli接口(Common python rpc and cli interface)
  • Mysql DB单个字段匹配多个其他字段(Mysql DB single field matching to multiple other fields)
  • 产品页面上的Magento Up出售对齐问题(Magento Up sell alignment issue on the products page)