Exemplo n.º 1
0
 public int UpdatePriceByPartNO(decimal? AID_COST, string VDR_PART)
 {
     String Query = "UPDATE Final_Table SET AID_COST = @AID_COST, AID_LastUpdate = @AID_LastUpdate WHERE VDR_PART = \"" + @VDR_PART + "\"";
     OleDbDataManager oDm = new OleDbDataManager(ConnectionString, Query, true);
     //oDm.AddVarcharPara("VDR_PART", 4000, VDR_PART);
     oDm.AddDecimalPara("AID_COST", 2, 10, AID_COST);
     oDm.AddVarcharPara("AID_LastUpdate", 4000, DateTime.Now.ToString());
     return oDm.RunActionQuery();
 }
Exemplo n.º 2
0
 public int Insert(Int64 ID, String UPC, String VDR_PART, String VDR_IT_DSC, String Image_Folder, String AID_SOURCE_ID, 
     String AID_PART, decimal AID_COST, String AID_IMG1, String AID_IMG2, String AID_VENDOR, String AID_INV, 
     Boolean AID_ClearanceZone, Boolean AID_HotDeals, Boolean AID_OnlineSpecials, Boolean AID_SaleCenter, Boolean AID_InStock, String AID_LastUpdate)
 {
     String Query = "INSERT INTO Final_Table (UPC, VDR_PART, VDR_IT_DSC, Image_Folder, AID_SOURCE_ID, AID_PART, AID_COST, AID_IMG1, AID_IMG2, AID_VENDOR, AID_INV, "
         + "AID_ClearanceZone, AID_HotDeals, AID_OnlineSpecials, AID_SaleCenter, AID_InStock, AID_LastUpdate)"
         + " VALUES (@UPC, @VDR_PART, @VDR_IT_DSC, @Image_Folder, @AID_SOURCE_ID, @AID_PART, @AID_COST, @AID_IMG1, @AID_IMG2, @AID_VENDOR, @AID_INV, "
         + "@AID_ClearanceZone, @AID_HotDeals, @AID_OnlineSpecials, @AID_SaleCenter, @AID_InStock, @AID_LastUpdate)";
     OleDbDataManager oDm = new OleDbDataManager(ConnectionString, Query, true);
     //oDm.AddIntegerBigPara("ID", ID);
     oDm.AddVarcharPara("UPC", 4000, UPC);
     oDm.AddVarcharPara("VDR_PART", 4000, VDR_PART);
     oDm.AddVarcharPara("VDR_IT_DSC", 4000, VDR_IT_DSC);
     oDm.AddVarcharPara("Image_Folder", 4000, Image_Folder);
     oDm.AddVarcharPara("AID_SOURCE_ID", 4000, AID_SOURCE_ID);
     oDm.AddVarcharPara("AID_PART", 4000, AID_PART);
     oDm.AddDecimalPara("AID_COST", 2, 10, AID_COST);
     oDm.AddVarcharPara("AID_IMG1", 4000, AID_IMG1);
     oDm.AddVarcharPara("AID_IMG2", 4000, AID_IMG2);
     oDm.AddVarcharPara("AID_VENDOR", 4000, AID_VENDOR);
     oDm.AddVarcharPara("AID_INV", 4000, AID_INV);
     oDm.AddBoolPara("AID_ClearanceZone", AID_ClearanceZone);
     oDm.AddBoolPara("AID_HotDeals", AID_HotDeals);
     oDm.AddBoolPara("AID_OnlineSpecials", AID_OnlineSpecials);
     oDm.AddBoolPara("AID_SaleCenter", AID_SaleCenter);
     oDm.AddBoolPara("AID_InStock", AID_InStock);
     oDm.AddVarcharPara("AID_LastUpdate", 4000, AID_LastUpdate);
     //oDm.AddIntegerPara("AID_LeastCount", AID_LeastCount);
     //oDm.AddBoolPara("AID_Priority", AID_Priority);
     return oDm.RunActionQuery();
 }
Exemplo n.º 3
0
        public int Update(Int64 ID, String UPC, String VDR_PART, String VDR_IT_DSC, String Image_Folder, String AID_SOURCE_ID, String AID_PART, 
            decimal AID_COST, String AID_IMG1, String AID_IMG2, String AID_VENDOR, String AID_INV, 
            Boolean AID_ClearanceZone, Boolean AID_HotDeals, Boolean AID_OnlineSpecials, Boolean AID_SaleCenter, Boolean AID_InStock, String AID_LastUpdate)
        {
            //String Query = "UPDATE Final_Table SET UPC = @UPC, VDR_PART = @VDR_PART, VDR_IT_DSC = @VDR_IT_DSC, Image_Folder = @Image_Folder, AID_SOURCE_ID = @AID_SOURCE_ID, AID_PART = @AID_PART, AID_COST = @AID_COST, AID_IMG1 = @AID_IMG1, AID_IMG2 = @AID_IMG2, AID_VENDOR = @AID_VENDOR, AID_INV = @AID_INV, AID_LastUpdate = @AID_LastUpdate, AID_LeastCount = @AID_LeastCount, AID_Priority = @AID_Priority"
            //    + " WHERE ID = @ID";

            String Query = "UPDATE Final_Table SET UPC = @UPC, VDR_PART = @VDR_PART, VDR_IT_DSC = @VDR_IT_DSC, Image_Folder = @Image_Folder"
                + ", AID_SOURCE_ID = @AID_SOURCE_ID, AID_PART = @AID_PART, AID_COST = @AID_COST, AID_IMG1 = @AID_IMG1, AID_IMG2 = @AID_IMG2"
                + ", AID_VENDOR = @AID_VENDOR, AID_INV = @AID_INV, AID_ClearanceZone = @AID_ClearanceZone, AID_HotDeals = @AID_HotDeals"
                + ", AID_OnlineSpecials= @AID_OnlineSpecials, AID_SaleCenter = @AID_SaleCenter, AID_InStock = @AID_InStock, AID_LastUpdate = @AID_LastUpdate"
                + " WHERE ID = " + ID.ToString();
            OleDbDataManager oDm = new OleDbDataManager(ConnectionString, Query, true);
            //oDm.AddIntegerBigPara("ID", ID);
            oDm.AddVarcharPara("UPC", 4000, UPC);
            oDm.AddVarcharPara("VDR_PART", 4000, VDR_PART);
            oDm.AddVarcharPara("VDR_IT_DSC", 4000, VDR_IT_DSC);
            oDm.AddVarcharPara("Image_Folder", 4000, Image_Folder);
            oDm.AddVarcharPara("AID_SOURCE_ID", 4000, AID_SOURCE_ID);
            oDm.AddVarcharPara("AID_PART", 4000, AID_PART);
            oDm.AddDecimalPara("AID_COST", 2, 10, AID_COST);
            oDm.AddVarcharPara("AID_IMG1", 4000, AID_IMG1);
            oDm.AddVarcharPara("AID_IMG2", 4000, AID_IMG2);
            oDm.AddVarcharPara("AID_VENDOR", 4000, AID_VENDOR);
            oDm.AddVarcharPara("AID_INV", 4000, AID_INV);
            oDm.AddBoolPara("AID_ClearanceZone", AID_ClearanceZone);
            oDm.AddBoolPara("AID_HotDeals", AID_HotDeals);
            oDm.AddBoolPara("AID_OnlineSpecials", AID_OnlineSpecials);
            oDm.AddBoolPara("AID_SaleCenter", AID_SaleCenter);
            oDm.AddBoolPara("AID_InStock", AID_InStock);
            oDm.AddVarcharPara("AID_LastUpdate", 4000, AID_LastUpdate);
            ////oDm.AddIntegerPara("AID_LeastCount", AID_LeastCount);
            ////oDm.AddBoolPara("AID_Priority", AID_Priority);
            return oDm.RunActionQuery();
        }
        public int Update(Int64 ID, String UPC, String VDR_PART, String VDR_IT_DSC, String Image_Folder, String AID_SOURCE_ID, String AID_PART, decimal AID_COST, String AID_IMG1, String AID_IMG2, String AID_VENDOR, String AID_INV, String AID_LastUpdate)
        {
            String Query = "UPDATE Final_Table SET [UPC] = @UPC, [VDR_PART] = @VDR_PART, [VDR_IT_DSC] = @VDR_IT_DSC, [Image_Folder] = @Image_Folder, [AID_SOURCE_ID] = @AID_SOURCE_ID,"
                + " [AID_PART] = @AID_PART, [AID_COST] = @AID_COST, [AID_IMG1] = @AID_IMG1, [AID_IMG2] = @AID_IMG2, [AID_VENDOR] = @AID_VENDOR, [AID_INV] = @AID_INV, [AID_LastUpdate] = @AID_LastUpdate"
                + " WHERE [ID] = " + ID.ToString(); // " @ID";

            OleDbDataManager oDm = new OleDbDataManager(ConnectionString, Query, true);
            //oDm.AddIntegerPara("@ID", (int) ID);
            oDm.AddVarcharPara("@UPC", 4000, UPC);
            oDm.AddVarcharPara("@VDR_PART", 4000, VDR_PART);
            oDm.AddVarcharPara("@VDR_IT_DSC", 4000, VDR_IT_DSC);
            oDm.AddVarcharPara("@Image_Folder", 4000, Image_Folder);
            oDm.AddVarcharPara("@AID_SOURCE_ID", 4000, AID_SOURCE_ID);
            oDm.AddVarcharPara("@AID_PART", 4000, AID_PART);
            oDm.AddDecimalPara("@AID_COST", 2, 10, AID_COST);
            oDm.AddVarcharPara("@AID_IMG1", 4000, AID_IMG1);
            oDm.AddVarcharPara("@AID_IMG2", 4000, AID_IMG2);
            oDm.AddVarcharPara("@AID_VENDOR", 4000, AID_VENDOR);
            oDm.AddVarcharPara("@AID_INV", 4000, AID_INV);
            oDm.AddVarcharPara("@AID_LastUpdate", 4000, AID_LastUpdate);
            return oDm.RunActionQuery();
        }