예제 #1
0
        public void MODIFY(Firm item)
        {
            StringBuilder sb = new StringBuilder();

            sb.AppendFormat("update FIRMS set title={0} where idx={1}", item.title, item.idx);

            using (FirebirdDBHelper db = new FirebirdDBHelper(sb.ToString(), util.strDBConn))
            {
                try
                {
                    int count = db.GetEffectedCount();
                }
                catch (FirebirdSql.Data.FirebirdClient.FbException fex)
                {
                    db.Rollback();
                    util.WriteLog(string.Format("{0} MODIFY ERR : {1}", this.GetType(), fex.Message));
                    return;
                }
            }

            INIT();
        }
예제 #2
0
파일: Firm.cs 프로젝트: step4u/CallService
        public void ADD(Firm item)
        {
            StringBuilder sb = new StringBuilder();
            sb.Append("insert into FIRMS");
            sb.Append("( title )");
            sb.Append(" values ");
            sb.AppendFormat("( {0} )", item.title);

            using (FirebirdDBHelper db = new FirebirdDBHelper(sb.ToString(), util.strDBConn))
            {
                try
                {
                    int count = db.GetEffectedCount();
                }
                catch (FirebirdSql.Data.FirebirdClient.FbException fex)
                {
                    db.Rollback();
                    util.WriteLog(string.Format("{0} ADD ERR : {1}", this.GetType(), fex.Message));
                    return;
                }
            }

            INIT();
        }
예제 #3
0
파일: Firm.cs 프로젝트: step4u/CallService
        public void MODIFY(Firm item)
        {
            StringBuilder sb = new StringBuilder();
            sb.AppendFormat("update FIRMS set title={0} where idx={1}", item.title, item.idx);

            using (FirebirdDBHelper db = new FirebirdDBHelper(sb.ToString(), util.strDBConn))
            {
                try
                {
                    int count = db.GetEffectedCount();
                }
                catch (FirebirdSql.Data.FirebirdClient.FbException fex)
                {
                    db.Rollback();
                    util.WriteLog(string.Format("{0} MODIFY ERR : {1}", this.GetType(), fex.Message));
                    return;
                }
            }

            INIT();
        }