Excel: Merge two columns into one column with alte

2020-05-02 02:40发布

how can I merge two columns of data into one like the following:

Col1    Col2    Col3
========================
A       1       A
B       2       1
C       3       B
                2
                C
                3

2条回答
不美不萌又怎样
2楼-- · 2020-05-02 03:21

You can use the following formula in column D as per my example. Keep in mind to increase the $A$1:$B$6 range according to your data.

=INDEX($A$1:$B$6,INT((ROWS(D$2:D2)-1)/2)+1,MOD(ROWS(D$2:D2)-1,2)+1)

Result:

enter image description here

查看更多
叼着烟拽天下
3楼-- · 2020-05-02 03:38

Thank you to @Koby Douek for the answer. Just an addition--if you are using Open Office Calc, you replace the commas with semi-colons.

=INDEX($A$1:$B$6;INT((ROWS(D$2:D2)-1)/2)+1;MOD(ROWS(D$2:D2)-1;2)+1)
查看更多
登录 后发表回答