Why vlookup return error when i moved reference data?

i want to keep a record my ate meal everyday.
i make egg(one) data in sheet2.
i want to use row 6 data as variable in programing.

i try to get row6 data by vlookup function in a2 cell.
but when i moved row6 data,b2 and c2 get error.

how to get row6 data without getting a error?
please help,

step1 i write this formula to a2 cell.
=VLOOKUP(A6,A6:D6,1)
sorry i changed this formula.

step2 i use fill copy to D2 from A2.

step3 i moved reference data.but i get error in row 2.

How do you move and what does the formula look like after the move?

Row 9 is empty until step 3, so in step 1 formula is
=VLOOKUP(A6,A6:D6,1)

But there is a bug here, when you cut and paste row 6 to row 9. I’ll need to search a bit more. Someone shared it here a few days ago.

I think that a better formula is =VLOOKUP($A9;$A9:$D9;COLUMN())
Note the use of semicolon instead of comma.

EDIT: My bad. It was not a bug report, but a question: Formula incorrect after paste special
Anyway, actual question could show a bug.

@erAck ,thanks for comment.b2,c2,d2 formula is like this after the moved to row 9.
=VLOOKUP(B9,B6:E6,1)
=VLOOKUP(C9,C6:F6,1)
=VLOOKUP(D9,C6:F6,1)

@LeroyG ,sorry i missed formula in example and fixed it.
i write formula of b2,c2,d2 in previous replay.

it this bug?really?

You still did not answer how you move the data row. If in row 2 I have

A B C D
=VLOOKUP(A6;A6:D6;1) =VLOOKUP(A6;A6:D6;2) =VLOOKUP(A6;A6:D6;3) =VLOOKUP(A6;A6:D6;4)

and then select A6:D6, Cut (Ctrl+X), and Paste (Ctrl+V) on A9 then the formulas are correctly adjusted to =VLOOKUP(A9;A9:D9;1) and =VLOOKUP(A9;A9:D9;2) … and the results are still the same. The same if I drag&drop the selection of A6:D6 to row 9.

The examples you give suggest that you did something completely different.

1 Like

erArk
thanks for comment.
i may be use vlookup incorrectly.
i set this formula in A2 cell.next time i use fill copy to D2 from A2.
=VLOOKUP(A6,A6:D6,1)

your sample work well,when i moved 6row to 9row.i not get error.

thanks.