Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I have a big data and I would like to move data from column 1 to odd positions in column 2 (see the picture). Thanks in advance for your help!

enter image description here


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
4.1k views
Welcome To Ask or Share your Answers For Others

1 Answer

If you only need to do this once:

  • Insert a new column
  • enter the numbers 1 and 3 into the first cells next to the first two data items
  • use the fill handle to drag down with incrementing in steps of 2, so all data items have an odd number in the neighbouring column.
  • in the same column, below the last odd number, enter 2 and in the next row 4
  • use the fill handle and drag down until you have a number bigger than the last odd number.
  • Now select the data column and the numbers and sort by the numbers column.
  • move to your desired position and delete what you no longer need.

You can also use a formula along these lines:

=IF(INT(ROW()/2)=ROW()/2,INDEX(A:A,ROW()/2),"")

Then copy and paste as values over the data.

enter image description here


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...