Can someone tell me what the syntax error is in this code?
DoCmd.RunSQL ("INSERT INTO tbl_ats_Comm_Draw_Hist ( [Key], Cust_ID, Inv_Num, Tran_Type, Inv_Date, Inv_Amt, Sls_RepID )SELECT ARTAP.Seq_no, ARTAP.CustID, ARTAP.InvNum, ARTAP.TranType, ARTAP.Date, ARTAP.Amount, ARTAP.Rep_1)FROM ARTAP WHERE ((ARTAP.TranType)="L") AND ((ARTAP.Contract_type)="B"))
This is in a command buttons code.
Thank you.
DoCmd.RunSQL ("INSERT INTO tbl_ats_Comm_Draw_Hist ( [Key], Cust_ID, Inv_Num, Tran_Type, Inv_Date, Inv_Amt, Sls_RepID )SELECT ARTAP.Seq_no, ARTAP.CustID, ARTAP.InvNum, ARTAP.TranType, ARTAP.Date, ARTAP.Amount, ARTAP.Rep_1)FROM ARTAP WHERE ((ARTAP.TranType)="L") AND ((ARTAP.Contract_type)="B"))
This is in a command buttons code.
Thank you.