private bool CheckVoyageExistInList2(string voyageno) { string sql = "select count(1) from EHS_SCAN_LIST2 where VOYAGE_NO = @VOYAGE_NO"; Hashtable ht = new Hashtable(); ht["VOYAGE_NO"] = voyageno; return(comm.Exists(sql, ht)); }
public bool CheckBiLLNOExist(string billNo) { string sql = "select count(1) from LH_V1 where BILL_NO=@BILL_NO and HY_NAME=@HY_NAME"; Hashtable ht = new Hashtable(); ht["BILL_NO"] = billNo; ht["HY_NAME"] = _HYNAME; return(comm.Exists(sql, ht)); }
public bool CheckUserNameExist(string newName, int id = 0) { if (id > 0) { string sql = "select count(1) from users where loginname = @loginname and id != @id"; Hashtable ht = new Hashtable(); ht["loginname"] = newName; ht["id"] = id; return(comm.Exists(sql, ht)); } else { string sql = "select count(1) from users where loginname = @loginname"; Hashtable ht = new Hashtable(); ht["loginname"] = newName; return(comm.Exists(sql, ht)); } }