compare two column each other

majidsiddique

Board Regular
Joined
Oct 22, 2018
Messages
164
hi all:

i comparing two table with formula: serial and Lot
i used this formula:

=IF(H2=0,IF(C2=I2,"match","not match"),VLOOKUP(H2,$B$2:$B$21,2,0))
column can be assumed as excel file.

vlookup paste value, i want paste match or not match. kindly tell me is it possible with formula. i am using if when condition false but not working.

[TABLE="class: grid, width: 700"]
<tbody>[TR]
[TD][TABLE="class: grid, width: 807"]
<colgroup><col><col><col><col><col><col><col><col><col><col><col></colgroup><tbody>[TR]
[TD]ITEM[/TD]
[TD]SERIAL[/TD]
[TD]LOT[/TD]
[TD]EXPIRY[/TD]
[TD]Total[/TD]
[TD][/TD]
[TD]R. #[/TD]
[TD]Serial #[/TD]
[TD]Lot[/TD]
[TD]Exp Date[/TD]
[TD]Qty[/TD]
[/TR]
[TR]
[TD]MD-120100000[/TD]
[TD] [/TD]
[TD]2018031054[/TD]
[TD]31/03/2021[/TD]
[TD]120[/TD]
[TD][/TD]
[TD]MD-120100000[/TD]
[TD] [/TD]
[TD]2018031054[/TD]
[TD]31/03/2021[/TD]
[TD]120[/TD]
[/TR]
[TR]
[TD] [/TD]
[TD] [/TD]
[TD]2018031305[/TD]
[TD]31/03/2021[/TD]
[TD]200[/TD]
[TD][/TD]
[TD] [/TD]
[TD] [/TD]
[TD]2018031305[/TD]
[TD]31/03/2021[/TD]
[TD]200[/TD]
[/TR]
[TR]
[TD]MD-120120000[/TD]
[TD] [/TD]
[TD]2018030052[/TD]
[TD]31/03/2021[/TD]
[TD]40[/TD]
[TD][/TD]
[TD]MD-120120000[/TD]
[TD] [/TD]
[TD]2018030052[/TD]
[TD]31/03/2021[/TD]
[TD]40[/TD]
[/TR]
[TR]
[TD]MD-120130000[/TD]
[TD] [/TD]
[TD]2018031058[/TD]
[TD]31/03/2021[/TD]
[TD]40[/TD]
[TD][/TD]
[TD]MD-120130000[/TD]
[TD] [/TD]
[TD]2018031058[/TD]
[TD]31/03/2021[/TD]
[TD]40[/TD]
[/TR]
[TR]
[TD] [/TD]
[TD] [/TD]
[TD]2018040083[/TD]
[TD]30/04/2021[/TD]
[TD]100[/TD]
[TD][/TD]
[TD] [/TD]
[TD] [/TD]
[TD]2018040083[/TD]
[TD]30/04/2021[/TD]
[TD]100[/TD]
[/TR]
[TR]
[TD] [/TD]
[TD] [/TD]
[TD]2018050903[/TD]
[TD]31/05/2021[/TD]
[TD]160[/TD]
[TD][/TD]
[TD] [/TD]
[TD] [/TD]
[TD]2018050903[/TD]
[TD]31/05/2021[/TD]
[TD]160[/TD]
[/TR]
[TR]
[TD]MD-120160000[/TD]
[TD] [/TD]
[TD]2018041165[/TD]
[TD]30/04/2021[/TD]
[TD]40[/TD]
[TD][/TD]
[TD]MD-120160000[/TD]
[TD] [/TD]
[TD]2018041165[/TD]
[TD]30/04/2021[/TD]
[TD]40[/TD]
[/TR]
[TR]
[TD]MD-500DM2700[/TD]
[TD]27M882574[/TD]
[TD] [/TD]
[TD]12/03/2023[/TD]
[TD]1[/TD]
[TD][/TD]
[TD]MD-500DM2700[/TD]
[TD]27M882574[/TD]
[TD] [/TD]
[TD]01/01/1900[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD] [/TD]
[TD]27M887620[/TD]
[TD] [/TD]
[TD]12/03/2023[/TD]
[TD]1[/TD]
[TD][/TD]
[TD] [/TD]
[TD]27M887620[/TD]
[TD] [/TD]
[TD]01/01/1900[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD] [/TD]
[TD]27M887911[/TD]
[TD] [/TD]
[TD]14/03/2023[/TD]
[TD]1[/TD]
[TD][/TD]
[TD] [/TD]
[TD]27M887911[/TD]
[TD] [/TD]
[TD]01/01/1900[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD] [/TD]
[TD]27M887954[/TD]
[TD] [/TD]
[TD]14/03/2023[/TD]
[TD]1[/TD]
[TD][/TD]
[TD] [/TD]
[TD]27M887954[/TD]
[TD] [/TD]
[TD]01/01/1900[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD] [/TD]
[TD]27M887962[/TD]
[TD] [/TD]
[TD]14/03/2023[/TD]
[TD]1[/TD]
[TD][/TD]
[TD] [/TD]
[TD]27M887962[/TD]
[TD] [/TD]
[TD]01/01/1900[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD] [/TD]
[TD]27M887979[/TD]
[TD] [/TD]
[TD]14/03/2023[/TD]
[TD]1[/TD]
[TD][/TD]
[TD] [/TD]
[TD]27M887979[/TD]
[TD] [/TD]
[TD]01/01/1900[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD]MD-617700000[/TD]
[TD] [/TD]
[TD]1020[/TD]
[TD]28/03/2023[/TD]
[TD]200[/TD]
[TD][/TD]
[TD]MD-617700000[/TD]
[TD] [/TD]
[TD]1020[/TD]
[TD]28/03/2023[/TD]
[TD]200[/TD]
[/TR]
[TR]
[TD]MD-6207-SI00[/TD]
[TD] [/TD]
[TD]W4252877[/TD]
[TD]18/04/2020[/TD]
[TD]70[/TD]
[TD][/TD]
[TD]MD-6207-SI00[/TD]
[TD] [/TD]
[TD]W4252877[/TD]
[TD]18/04/2020[/TD]
[TD]70[/TD]
[/TR]
[TR]
[TD]MD-681300000[/TD]
[TD] [/TD]
[TD]2018031008[/TD]
[TD]31/03/2021[/TD]
[TD]20[/TD]
[TD][/TD]
[TD]MD-681300000[/TD]
[TD] [/TD]
[TD]2018031008[/TD]
[TD]31/03/2021[/TD]
[TD]20[/TD]
[/TR]
[TR]
[TD]MD-6947M-62C[/TD]
[TD]TDK016458G[/TD]
[TD] [/TD]
[TD]07/05/2020[/TD]
[TD]1[/TD]
[TD][/TD]
[TD]MD-6947M-62C[/TD]
[TD]TDK016458G[/TD]
[TD] [/TD]
[TD]01/01/1900[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD] [/TD]
[TD]TDK016459G[/TD]
[TD] [/TD]
[TD]07/05/2020[/TD]
[TD]1[/TD]
[TD][/TD]
[TD] [/TD]
[TD]TDK016459G[/TD]
[TD] [/TD]
[TD]01/01/1900[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD] [/TD]
[TD]TDK016462G[/TD]
[TD] [/TD]
[TD]07/05/2020[/TD]
[TD]1[/TD]
[TD][/TD]
[TD] [/TD]
[TD]TDK016462G[/TD]
[TD] [/TD]
[TD]01/01/1900[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD] [/TD]
[TD]TDK016463G[/TD]
[TD] [/TD]
[TD]07/05/2020[/TD]
[TD]1[/TD]
[TD][/TD]
[TD] [/TD]
[TD]TDK016463G[/TD]
[TD] [/TD]
[TD]01/01/1900[/TD]
[TD]1[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[/TR]
</tbody>[/TABLE]
 
Glad you got it working & thanks for the feedback
 
Upvote 0

Excel Facts

How to fill five years of quarters?
Type 1Q-2023 in a cell. Grab the fill handle and drag down or right. After 4Q-2023, Excel will jump to 1Q-2024. Dash can be any character.

Forum statistics

Threads
1,223,956
Messages
6,175,613
Members
452,661
Latest member
Nonhle

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top