得到正确的列总和(coldfusion)
我有一个按月列出产品的表,我找到了它们的行总和,我需要找到列总和,但我的列总和计数是错误的,我做错了什么?你可以在这里查看代码: http://jsfiddle.net/KRHbx/ 谢谢大家的帮助! ^.^
I have a table with products listed by month, i found row sum of them, and i need to find column sum, but my counts are wrong for column sums, what am i doing wrong? u can have a look at the code here:
http://jsfiddle.net/KRHbx/ thank you everyone for your help! ^.^
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我认为你的问题就在这里,你指的是递增 p_index 的循环之外的 p_index 。所以它总是引用你的product_id_list 的最后一个元素。
I think your problem is here, you're referring to p_index outside of the loop that increments p_index. So it's always going to be referring to the last element of your product_id_list.