I am trying this code to run an append query but I keep getting the error: syntax error in INSERT INTO statement. This is the statement i'm trying
DoCmd.RunSQL "INSERT INTO tblInventoryAdjustmentsArchive AdjustmentID, ProductID, MaterialsID, PackagingID, [Date], Comments, QtyOnHand, QtyCount SELECT tblInventoryAdjustment.AdjustmentID, tblInventoryAdjustment.ProductID, tblInventoryAdjustment.MaterialsID, tblInventoryAdjustment.PackagingID, tblInventoryAdjustment.Date, tblInventoryAdjustment.Comments, tblInventoryAdjustment.QtyOnHand, tblInventoryAdjustment.QtyCount FROM tblInventoryAdjustment;"
Any ideas?
DoCmd.RunSQL "INSERT INTO tblInventoryAdjustmentsArchive AdjustmentID, ProductID, MaterialsID, PackagingID, [Date], Comments, QtyOnHand, QtyCount SELECT tblInventoryAdjustment.AdjustmentID, tblInventoryAdjustment.ProductID, tblInventoryAdjustment.MaterialsID, tblInventoryAdjustment.PackagingID, tblInventoryAdjustment.Date, tblInventoryAdjustment.Comments, tblInventoryAdjustment.QtyOnHand, tblInventoryAdjustment.QtyCount FROM tblInventoryAdjustment;"
Any ideas?