First create sheet pages, [SheetA] and [SheetB]. The purpose of the operation is to match which data in the [SheetB] table exists in [SheetA] and match the corresponding [Material Name] column.
##Related recommendations: "php Getting Started Tutorial"
Select [SheetB] For the first item in the [Material Name] column, click [Formula] and select the [Insert Function] option. The [Insert Function] dialog box will pop up, then select the [vlookup] function and click [OK]. The parameter input dialog box of the [vlookup] function will pop up. We first select the first parameter, here, because We match based on the [Material Code] field in the two tables A/B. Therefore, in the corresponding line, the first parameter we enter is [A2], which represents the value of column A2. Then, determine the value of the second parameter. This is the key point. Because the data we want to compare is in Table A, for this second parameter, we need to jump to the [SheetA] table to select the data range. The selection here is [SheetA!A1:B30]. At the same time, because this area needs to be fixed so that it can be easily dragged and selected directly in the sequence, it is recommended to determine parameter 2 as [SheetA!$A$1:$B$30]. The next step is the value of the third parameter, because the goal of the operation is to return the value of [Material Name] corresponding to the corresponding material code in the SheetA table, and [Material Name] 】This field is located in the second column in the data range we selected [SheetA!$A$1:$B$30], so the value of the third parameter is confirmed to be [2]. The fourth parameter, this is also the key point. This function has an explanation for the function. According to the purpose of our operation, the final result must be accurately matched, so we define the value of the fourth function as [False]. This determines the definition of this function. Subsequently, as long as we drag down and select, Excel will automatically fill in the formula sequence and get the final matching result. If the matching result is [#N/A], it means that the corresponding material code does not exist in the [SheetA] table.The above is the detailed content of How to compare information from two tables in Excel. For more information, please follow other related articles on the PHP Chinese website!