ThisIsntMyRealName
Board Regular
- Joined
- May 23, 2009
- Messages
- 69
Hey guys, I have this query below, my goal is to simply INSERT all of the fields from one record into another table, plus add one more string field at the end of that, what is the syntax for this?
Here is my query so far:
CurrentDb.Execute "INSERT INTO [Adage_IMMP_Combined_Join_Live_Exceptions] (Order_ID_Adage, Order_ID_IMMP, Join_Key, POH_Adage, POH_IMMP, Item_ID_Adage, Item_ID_IMMP, WHS_Code_Adage, WHS_Code_IMMP, Qty_Adage, Qty_IMMP, Lot_Adage, Lot_IMMP, User_Adage, User_IMMP, Trans_Date_Adage, Trans_Date_IMMP, Report_Date_Start, Report_Date_End, System_Adage, System_IMMP) " _
& "SELECT [Adage_IMMP_Join].Order_ID_Adage, [Adage_IMMP_Join].Order_ID_IMMP, [Adage_IMMP_Join].Join_Key, [Adage_IMMP_Join].POH_Adage, [Adage_IMMP_Join].POH_IMMP, [Adage_IMMP_Join].Item_ID_Adage , [Adage_IMMP_Join].Item_ID_IMMP, [Adage_IMMP_Join].WHS_Code_Adage , [Adage_IMMP_Join].WHS_Code_IMMP, [Adage_IMMP_Join].Qty_Adage, [Adage_IMMP_Join].Qty_IMMP, [Adage_IMMP_Join].Lot_Adage, [Adage_IMMP_Join].Lot_IMMP, [Adage_IMMP_Join].User_Adage, [Adage_IMMP_Join].User_IMMP, [Adage_IMMP_Join].Trans_Date_Adage, [Adage_IMMP_Join].Trans_Date_IMMP, [Adage_IMMP_Join].Report_Date_Start, [Adage_IMMP_Join].Report_Date_End, [Adage_IMMP_Join].System_Adage, [Adage_IMMP_Join].System_IMMP FROM [Adage_IMMP_Join]", dbFailOnError
Here is my query so far:
CurrentDb.Execute "INSERT INTO [Adage_IMMP_Combined_Join_Live_Exceptions] (Order_ID_Adage, Order_ID_IMMP, Join_Key, POH_Adage, POH_IMMP, Item_ID_Adage, Item_ID_IMMP, WHS_Code_Adage, WHS_Code_IMMP, Qty_Adage, Qty_IMMP, Lot_Adage, Lot_IMMP, User_Adage, User_IMMP, Trans_Date_Adage, Trans_Date_IMMP, Report_Date_Start, Report_Date_End, System_Adage, System_IMMP) " _
& "SELECT [Adage_IMMP_Join].Order_ID_Adage, [Adage_IMMP_Join].Order_ID_IMMP, [Adage_IMMP_Join].Join_Key, [Adage_IMMP_Join].POH_Adage, [Adage_IMMP_Join].POH_IMMP, [Adage_IMMP_Join].Item_ID_Adage , [Adage_IMMP_Join].Item_ID_IMMP, [Adage_IMMP_Join].WHS_Code_Adage , [Adage_IMMP_Join].WHS_Code_IMMP, [Adage_IMMP_Join].Qty_Adage, [Adage_IMMP_Join].Qty_IMMP, [Adage_IMMP_Join].Lot_Adage, [Adage_IMMP_Join].Lot_IMMP, [Adage_IMMP_Join].User_Adage, [Adage_IMMP_Join].User_IMMP, [Adage_IMMP_Join].Trans_Date_Adage, [Adage_IMMP_Join].Trans_Date_IMMP, [Adage_IMMP_Join].Report_Date_Start, [Adage_IMMP_Join].Report_Date_End, [Adage_IMMP_Join].System_Adage, [Adage_IMMP_Join].System_IMMP FROM [Adage_IMMP_Join]", dbFailOnError