devxlogo

How to Link an Access Database with SQL Server

How to Link an Access Database with SQL Server

Question:
I want to extract/insert data by linking one Access table with a SQL server table through VB code. So far, I am not able to to it (using ADO 2.1). Can I write a query in VB similar to:

dbo_retired_hcpc - Sql Server TableTPARTBHCPCSecondFinder - Access tableselect * from dbo_retired_hcpc h, TPARTBHCPCSecondFinder twhere T.hcpc=h.hcpc and t.carrier=h.carrier and t.maint_dt = h.maint_dt) 

Answer:
Within SQL Server, you can certainly reference external tables. Take a look in SQL Enterprise Manager (whichever version you have) for instructions on how to link to an external database. Once you’ve got the database linked, you’ll be able to do queries like you suggested in the question.

See also  Why ChatGPT Is So Important Today
devxblackblue

About Our Editorial Process

At DevX, we’re dedicated to tech entrepreneurship. Our team closely follows industry shifts, new products, AI breakthroughs, technology trends, and funding announcements. Articles undergo thorough editing to ensure accuracy and clarity, reflecting DevX’s style and supporting entrepreneurs in the tech sphere.

See our full editorial policy.

About Our Journalist