public void UpdateCashBackPlan(CashbackCriteriaBO objBO)
        {
            string query =
                @"UPDATE SBP_Cashback_Plan
                  SET "
                + "[Plan_Name] ='" + objBO.PlanName + "'"
                + ",[Description] = '" + objBO.PlanDescription + "'"
                + ",[Plan_Date] = '" + objBO.PlanDate + "'"
                + ",[Min_Trade_Amount] = " + objBO.MinTradeAmount
                + ",[Rate] = " + objBO.Rate
                + ",[Effective_Date] = '" + objBO.EffectiveDate + "'"
                + ",[Entry_Date] = CONVERT(Datetime,CAST(FLOOR(CAST(GETDATE() AS FLOAT)) AS DATETIME))"
                + ",[Entry_By] = '" + GlobalVariableBO._userName + "'"
                + " WHERE ID=" + objBO.ID;

            try
            {
                _dbConnection.ConnectDatabase();
                _dbConnection.ExecuteNonQuery(query);
            }
            catch (Exception exception)
            {
                throw exception;
            }
            finally
            {
                _dbConnection.CloseDatabase();
            }
        }
        public void InsertCriteria(CashbackCriteriaBO cashBackCriteriaBo)
        {
            string queryString = "";

            //  CommonBAL commonBAL = new CommonBAL();
            //  cashBackCriteriaBo.ID = commonBAL.GenerateID("SBP_Cashback_Plan", "ID");ΜΆ

            queryString = @"SBPSaveCashBackPlan";
            try
            {
                _dbConnection.ConnectDatabase();
                _dbConnection.ActiveStoredProcedure();
                _dbConnection.AddParameter("@planName", SqlDbType.VarChar, cashBackCriteriaBo.PlanName);
                _dbConnection.AddParameter("@planDescription", SqlDbType.VarChar, cashBackCriteriaBo.PlanDescription);
                _dbConnection.AddParameter("@planDate", SqlDbType.DateTime, cashBackCriteriaBo.PlanDate.ToShortDateString());
                _dbConnection.AddParameter("@minTradeAmount", SqlDbType.Money, cashBackCriteriaBo.MinTradeAmount);
                _dbConnection.AddParameter("@Rate", SqlDbType.Float, cashBackCriteriaBo.Rate);
                _dbConnection.AddParameter("@effectiveDate", SqlDbType.DateTime, cashBackCriteriaBo.EffectiveDate.ToShortDateString());
                _dbConnection.AddParameter("@entryBy", SqlDbType.VarChar, GlobalVariableBO._userName);
                _dbConnection.ExecuteNonQuery(queryString);
            }
            catch (Exception exception)
            {
                throw exception;
            }
            finally
            {
                _dbConnection.CloseDatabase();
            }
        }