コード例 #1
0
        public bool InsertGVInfo(GvInfoVo vo)
        {
            int isChecked = 0;

            using (SqlCommand cmd = new SqlCommand())
            {
                cmd.Connection  = new SqlConnection(ConnectionString);
                cmd.CommandText = @"insert into GV_Master(GV_Code, GV_Name, GV_Status, GV_Group, Use_YN)
                                                values(@GV_Code, @GV_Name, @GV_Status, @GV_Group, @Use_YN)";
                cmd.Parameters.AddWithValue("@GV_Code", vo.GV_Code);
                cmd.Parameters.AddWithValue("@GV_Name", vo.GV_Name);
                cmd.Parameters.AddWithValue("@GV_Status", vo.GV_Status);
                cmd.Parameters.AddWithValue("@GV_Group", vo.GV_Group);
                cmd.Parameters.AddWithValue("@Use_YN", vo.Use_YN);
                cmd.Connection.Open();
                isChecked = cmd.ExecuteNonQuery();
                cmd.Connection.Close();
            }
            return(isChecked == 1 ? true: false);
        }
コード例 #2
0
ファイル: GVInfoService.cs プロジェクト: mwkim0402/Team1_MES2
        public bool InsertGVInfo(GvInfoVo vo)
        {
            GVInfoDAC dac = new GVInfoDAC();

            return(dac.InsertGVInfo(vo));
        }