By Andrew Gould
Writing SQL for Excel with ADODB playlist https://youtube.com/playlist?list=PLNIs-AWhQzckUd5i0E1xeSFeBAonYIurK
VBA Working with Databases playlist https://youtube.com/playlist?list=PLNIs-AWhQzclbRVLCZlsFvpz6fz2nPGbt
Get files here https://www.wiseowl.co.uk/vba-macros/videos/vba-ado-net-recordsets/sql-excel-union-multiple-files/
If you'd like to help fund Wise Owl's conversion of tea and biscuits into quality training videos, you can click this link https://www.wiseowl.co.uk/donate?t=1 to make a donation. Thanks for watching!
This video demonstrates how to use the IN clause (not to be confused with the IN operator!) in an ADODB SQL query to select data from multiple files in the same query. You'll learn how to union tables from multiple Excel workbooks, both with and without header rows. As a bonus, you'll also see how to union data from a CSV file.
Chapters
00:00 Topic List
00:31 The Basic Setup
02:30 A Basic Union Query
03:50 Using the IN Clause to Refer to a File
06:52 Adding an ORDER BY Clause
07:37 Adding another Workbook
08:38 Adding a Sheet with No Headers
10:20 Adding a CSV File
Visit www.wiseowl.co.uk for more online training resources in Microsoft Excel, Power BI, DAX, SQL Server, Reporting Services, Analysis Services, Integration Services, ASP.NET, C#, Visual Basic, Microsoft Access and more