简体   繁体   English

具有最大数量 Power BI 的索引

[英]Index with max number Power BI

I need some help with indexing tables with a cap on the index number.我需要一些关于索引表索引号上限的帮助。

The goal is an index from lets say 1:15.目标是让我们说 1:15 的索引。 When the index reaches 15, then it should do another iteration of 1:15 indexing until the end.当索引达到 15 时,它应该再次进行 1:15 索引的迭代,直到结束。 The number is dependent on another index in another table with no relationship.该数字依赖于另一个表中的另一个索引,没有任何关系。

Any recommendations on how to proceed?关于如何进行的任何建议?

Any help would be much appreciated任何帮助将非常感激

Add your index, developed any way you like.添加您的索引,以您喜欢的任何方式开发。 Then add a custom column that uses Number.Mod to convert the first column into repeating number groups.然后添加一个使用 Number.Mod 将第一列转换为重复数字组的自定义列。 The below counts sequentially from 0...X then converts that to repeating numbers of 1...15 in a second column.下面从 0...X 开始依次计数,然后将其转换为第二列中 1...15 的重复数字。 Delete the original index after删除原索引后

letSource = Excel.CurrentWorkbook(){[Name="Table1"]}[Content],
#"Added Index" = Table.AddIndexColumn(Source, "Index", 0, 1),
#"Added Custom" = Table.AddColumn(#"Added Index", "NewIndex", each 1+Number.Mod([Index],15))
in #"Added Custom"

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM