Marcus Aurelius
asked on
INSERT contents of one table...into an existing table....?
Experts:
Can I get the syntax for entering TableA into TableB. TableA contains the historical data and TableB has new data that needs to be populated INTO TableA.
Identical Columns....datatypes...etc ..etc..
Thanks
MikeV
Can I get the syntax for entering TableA into TableB. TableA contains the historical data and TableB has new data that needs to be populated INTO TableA.
Identical Columns....datatypes...etc
Thanks
MikeV
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
thanks....so there isn't a way to use a WILDCARD Character...like
INSERT INTO TableB ( col1, col2, col3 .... )
SELECT * <---------- ???
FOM tableA
WHERE ...
INSERT INTO TableB ( col1, col2, col3 .... )
SELECT * <---------- ???
FOM tableA
WHERE ...
if both tables are REALLY identical, then you could do this:
INSERT INTO TableB
SELECT *
FOM tableA
WHERE ...
note that it is usually dangerous for be used in production...
INSERT INTO TableB
SELECT *
FOM tableA
WHERE ...
note that it is usually dangerous for be used in production...
ASKER
Ok..I would be running this SQL script manually...and the data tables are IDENTICAL in column names etc...
Thanks for the information....
Thanks for the information....
Select Col1, Col2, Col3...
From TableB