Create 3 tables in 1 "Make Table" query

gmazza76

Well-known Member
Joined
Mar 19, 2011
Messages
739
Office Version
  1. 365
Platform
  1. Windows
Good morning,

This maybe a daft question, but instead of making 3 queries to create 3 new tables can I create 1 query that will automatically "append" or "Make Table" to 3 existing tables?

thanks
Gavin
 

Excel Facts

Convert text numbers to real numbers
Select a column containing text numbers. Press Alt+D E F to quickly convert text to numbers. Faster than "Convert to Number"

Joe4

MrExcel MVP, Junior Admin
Joined
Aug 1, 2002
Messages
67,156
Office Version
  1. 365
Platform
  1. Windows
Good morning,

This maybe a daft question, but instead of making 3 queries to create 3 new tables can I create 1 query that will automatically "append" or "Make Table" to 3 existing tables?

thanks
Gavin
I am pretty sure that a Make Table or Append Query can only write to a single table.
So if you want to write to three different tables, I believe you will need three different action queries.

Note that if you set them all up, you can add them all to a single Macro, so you can run all three with a single click.
 
Upvote 0
Solution

gmazza76

Well-known Member
Joined
Mar 19, 2011
Messages
739
Office Version
  1. 365
Platform
  1. Windows
I am pretty sure that a Make Table or Append Query can only write to a single table.
So if you want to write to three different tables, I believe you will need three different action queries.

Note that if you set them all up, you can add them all to a single Macro, so you can run all three with a single click.
Cheers @Joe4 I thought as much just needed to check
 
Upvote 0

welshgasman

Well-known Member
Joined
May 25, 2013
Messages
1,088
Office Version
  1. 2007
Platform
  1. Windows
Are the fields the same for all three queries?, if so, perhaps may we ask why?
 
Upvote 0

gmazza76

Well-known Member
Joined
Mar 19, 2011
Messages
739
Office Version
  1. 365
Platform
  1. Windows
All fields are the same @welshgasman, I can do 3 queries but I wanted to make things easier for the team I work on so they can link the files that are created (1 file per area for loading purposes) so that they have a file that doesn't lock and feeds a hierarchy into their business reports that is the same.
 
Upvote 0

welshgasman

Well-known Member
Joined
May 25, 2013
Messages
1,088
Office Version
  1. 2007
Platform
  1. Windows
All fields are the same @welshgasman, I can do 3 queries but I wanted to make things easier for the team I work on so they can link the files that are created (1 file per area for loading purposes) so that they have a file that doesn't lock and feeds a hierarchy into their business reports that is the same.
That would raise the question of normalization?, as you should likely have the one table with a field to identify what 'table' it was meant to be?

My thoughts were to amend the qdf of one query with VBA, but that is just so you do not need to maintain 3 queries. It would still need to run 3 times.
 
Upvote 0

Forum statistics

Threads
1,191,705
Messages
5,988,185
Members
440,136
Latest member
dandanfielding

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
Top