If combined with Vlookup in MS Access

excel_1317

Board Regular
Joined
Jun 28, 2010
Messages
212
I am new to Access, just wanted to ensure that is below is achievable in MS Access.

=IF(IFNA(VLOOKUP(C4,$A:$A,1,0),"")=C4,"Yes","No")


So, I have 2 tables in Access, i just want to create a query which lookup Account number from in Table 1 in Table 2 and return a Yes if the account number is present in Table 2 and No if Account Number is not present in table 2. Just like above excel function.
 
You want to write a Query using Left Join.
Code:
Select 
    Table1.AccountNumber, 
    IIf(IsNull(Table2.AccountNumber), "No", "Yes") AS MyOtherColumn
From
    Table1
    Left Join Table2
    On Table1.AccountNumber = Table2.AccountNumber

Note that depending on what your ultimate aim is, you can also use the unmatched records wizard, although personally I prefer to write my own SQL.


Thanks a lot!!
 
Upvote 0

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.

Forum statistics

Threads
1,225,674
Messages
6,186,371
Members
453,350
Latest member
mjohnston819

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