public string getUpDownServerPKName(string path, string serverPK, int operation, out string NewServerPK) { UserModel model = new UserDal(); DB_OPT dbo = new DB_OPT(); model.GetUpDownStream(path, serverPK, operation, out NewServerPK, dbo); string sQLString = "select t.inpk from gov_tc_db_servicesmess t where trim(pk)=:pk"; OracleParameter[] cmdParms = new OracleParameter[] { new OracleParameter(":pk", OracleType.VarChar, 50) }; cmdParms[0].Value = NewServerPK; DataSet set = DbHelperOra.Query(sQLString, cmdParms); if (set.Tables[0].Rows.Count > 0) { return set.Tables[0].Rows[0][0].ToString(); } return ""; }
public static void GetUpDownStream(Page page, string serverPK, int operation, out string NewServerPK) { string str = page.Request.Url.ToString(); int startIndex = str.LastIndexOf("/") + 1; int num2 = str.LastIndexOf("?"); string path = (num2 < 0) ? str.Substring(startIndex) : str.Substring(startIndex, num2 - startIndex); UserModel model = new UserDal(); DB_OPT dbo = new DB_OPT(); model.GetUpDownStream(path, serverPK, operation, out NewServerPK, dbo); }