Example #1
0
        public bool Update()
        {
            bool flag = false;

            using (PersistentManager persistentManager = new PersistentManager())
            {
                ParameterDao dao = new ParameterDao();

                string sql = string.Format("update WMS_PARAMETER set DBTYPE_1='{1}',SERVERNAME_1='{2}',DBNAME_1='{3}',USERID_1='{4}',PWD_1='{5}',DBTYPE_2='{6}',SERVERNAME_2='{7}',DBNAME_2='{8}',USERID_2='{9}',PWD_2='{10}',DBTYPE_3='{11}',SERVERNAME_3='{12}',DBNAME_3='{13}',USERID_3='{14}',PWD_3='{15}',CELL_IMG_X='{16}',CELL_IMG_Y='{17}',SPACE_Z='{18}'  where ID='{0}'"
                                           , this.ID,
                                           this.DBTYPE_1,
                                           this.SERVERNAME_1,
                                           this.DBNAME_1,
                                           this.USERID_1,
                                           this.PWD_1,
                                           this.DBTYPE_2,
                                           this.SERVERNAME_2,
                                           this.DBNAME_2,
                                           this.USERID_2,
                                           this.PWD_2,
                                           this.DBTYPE_3,
                                           this.SERVERNAME_3,
                                           this.DBNAME_3,
                                           this.USERID_3,
                                           this.PWD_3,
                                           this.CELL_IMG_X,
                                           this.CELL_IMG_Y,
                                           this.SPACE_Z);

                dao.SetData(sql);
                flag = true;
            }
            return(flag);
        }
Example #2
0
        public bool Insert()
        {
            bool flag = false;

            using (PersistentManager persistentManager = new PersistentManager())
            {
                ParameterDao dao = new ParameterDao();

                string sql = string.Format("Insert into WMS_PARAMETER (DBTYPE_1,SERVERNAME_1,DBNAME_1,USERID_1,PWD_1,DBTYPE_2,SERVERNAME_2,DBNAME_2,USERID_2,PWD_2,DBTYPE_3,SERVERNAME_3,DBNAME_3,USERID_3,PWD_3,CELL_IMG_X,CELL_IMG_Y,SPACE_Z) values('{0}','{1}','{2}','{3}','{4}','{5}','{6}','{7}','{8}','{9}','{10}','{11}','{12}','{13}','{14}','{15}','{16}','{17}')"
                                           , this.DBTYPE_1,
                                           this.SERVERNAME_1,
                                           this.DBNAME_1,
                                           this.USERID_1,
                                           this.PWD_1,
                                           this.DBTYPE_2,
                                           this.SERVERNAME_2,
                                           this.DBNAME_2,
                                           this.USERID_2,
                                           this.PWD_2,
                                           this.DBTYPE_3,
                                           this.SERVERNAME_3,
                                           this.DBNAME_3,
                                           this.USERID_3,
                                           this.PWD_3,
                                           this.CELL_IMG_X,
                                           this.CELL_IMG_Y,
                                           this.SPACE_Z);

                dao.SetData(sql);
                flag = true;
            }
            return(flag);
        }