G
Guest
I have this Code to INSERT INTO my Table named: BOM_EDIT_BuckUp with fields:
(Base_ID_B, Code_Sub_B, Part_ID_B, Description_B, QtyPer1_B, UOM_B)"
and I want to get them from my Table named: tbl_BOM with these records:
Base_ID, Code_Sub, Part_ID, Description, QtyPer1, UOM, FROM tbl_BOM just a
"_B" was added in the BackUp table,
but I want to Insert them, if Base_ID (this Data is from tbl-BOM table) =
[ComboPI] (this is a combo that Filter Datas in the subForm, and are equal to
Base_ID)
I running this code in a Form named:BOM_PRINT and the SubForm where all
records are filtered is: QueryBOMsubform
could you please help...
=================================================
DoCmd.SetWarnings False
DoCmd.RunSQL "INSERT INTO BOM_EDIT_BuckUp (Base_ID_B, Code_Sub_B,
Part_ID_B, Description_B, QtyPer1_B, UOM_B)" & _
"SELECT Base_ID, Code_Sub, Part_ID, Description, QtyPer1, UOM, FROM
tbl_BOM" & _
"WHERE Base_ID = ([ComboPI])"
DoCmd.SetWarnings True
=================================================
(Base_ID_B, Code_Sub_B, Part_ID_B, Description_B, QtyPer1_B, UOM_B)"
and I want to get them from my Table named: tbl_BOM with these records:
Base_ID, Code_Sub, Part_ID, Description, QtyPer1, UOM, FROM tbl_BOM just a
"_B" was added in the BackUp table,
but I want to Insert them, if Base_ID (this Data is from tbl-BOM table) =
[ComboPI] (this is a combo that Filter Datas in the subForm, and are equal to
Base_ID)
I running this code in a Form named:BOM_PRINT and the SubForm where all
records are filtered is: QueryBOMsubform
could you please help...
=================================================
DoCmd.SetWarnings False
DoCmd.RunSQL "INSERT INTO BOM_EDIT_BuckUp (Base_ID_B, Code_Sub_B,
Part_ID_B, Description_B, QtyPer1_B, UOM_B)" & _
"SELECT Base_ID, Code_Sub, Part_ID, Description, QtyPer1, UOM, FROM
tbl_BOM" & _
"WHERE Base_ID = ([ComboPI])"
DoCmd.SetWarnings True
=================================================