根据格值把行复制多遍
Excel表格的每行代表一种产品,第3列表示该产品数量。
A |
B |
C |
D |
E |
F |
|
1 |
F |
Designation |
Quantity |
Length-raw |
Width-raw |
Thickness-raw |
2 |
A |
4LLW |
2 |
2795 |
1250 |
18 |
3 |
B |
16LLWW |
3 |
2700 |
90 |
18 |
4 |
C |
1LLW |
4 |
2500 |
1250 |
18 |
5 |
D |
5LLW |
2 |
2500 |
1250 |
18 |
6 |
E |
2LLW |
5 |
2500 |
1100 |
18 |
7 |
F |
6LLWW |
4 |
2500 |
450 |
18 |
8 |
G |
DeskFront2 LLWW |
1 |
2414 |
1164 |
18 |
9 |
H |
Desk Shelf 1LLWW |
1 |
2414 |
300 |
18 |
请根据第3列的格值把每一行都复制多遍,原来的第3列显示为空格。
A |
B |
C |
D |
E |
F |
|
11 |
F |
Designation |
Quantity |
Length-raw |
Width-raw |
Thickness-raw |
12 |
A |
4LLW |
2795 |
1250 |
18 |
|
13 |
A |
4LLW |
2795 |
1250 |
18 |
|
14 |
B |
16LLWW |
2700 |
90 |
18 |
|
15 |
B |
16LLWW |
2700 |
90 |
18 |
|
16 |
B |
16LLWW |
2700 |
90 |
18 |
|
17 |
C |
1LLW |
2500 |
1250 |
18 |
|
18 |
C |
1LLW |
2500 |
1250 |
18 |
|
19 |
C |
1LLW |
2500 |
1250 |
18 |
|
20 |
C |
1LLW |
2500 |
1250 |
18 |
|
21 |
D |
5LLW |
2500 |
1250 |
18 |
|
22 |
D |
5LLW |
2500 |
1250 |
18 |
使用 SPL XLL
=spl("=?.conj(~3 * [~]).run(~3=null)",A2:F9)
函数 conj 用来合并序列成员,run 修改序列,"整数 N* 序列" 表示把序列成员复制 N 遍。
来源:https://www.reddit.com/r/excel/comments/1cjhvzx/what_formula_to_create_multiple_copies_of_a_row/
英文版 https://c.scudata.com/article/1723621007064