//检查K好在case_info中有数据 public Boolean checkCaseInfo(string kno) { string oracleSid = textBox4.Text.Trim(); string oracleName = textBox5.Text.Trim(); string oraclePwd = textBox6.Text.Trim(); string constring = "Data Source=" + oracleSid + ";Persist Security Info=True;User ID=" + oracleName + ";Password="******";Unicode=True"; DBHelperORACLE doo = new DBHelperORACLE(constring); string sql = "select count(id) from xcky.kct_case_info where kct_uuid = '52813100500148620140730230647098' and investigation_id =(select id from xcky.scene_investigation where investigation_no = '" + kno + "')"; Object c = doo.execScalar(sql); int count = int.Parse(c.ToString()); if (count > 0) { return(false);; } else { return(true); } }
//检测是否是2.0版本 public Boolean isSupport() { string oracleSid = textBox4.Text.Trim(); string oracleName = textBox5.Text.Trim(); string oraclePwd = textBox6.Text.Trim(); string constring = "Data Source=" + oracleSid + ";Persist Security Info=True;User ID=" + oracleName + ";Password="******";Unicode=True"; DBHelperORACLE doo = new DBHelperORACLE(constring); string sql = "select count(*) from user_tables where table_name like 'KCT%'"; Object c = doo.execScalar(sql); int count = int.Parse(c.ToString()); if (count > 0) { return(true); } else { return(false); } }