In the table of the first task the similar formula works. Also, if I substitute in the table of the second task from the table of the first, everything will also work.
For Vlookup, the value you are looking for must be in the first column of the range. Therefore, it is not suitable for the second task (the "Tab. Number" column is at the end of the specified range). Use the Match Index functions.