Oracle获取当前session ID的方法 1.使用v$mystat视图获取当前session的ID select sid from v$mystat; 2.使用userenv内部函数获取当前session的ID select userenv('sid') from dual