![](https://img-blog.csdnimg.cn/20201014180756925.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
数据库
你_如风
我和我自己的倔强我在风中大声地唱
展开
-
MYSQL存储过程带游标
create procedure updateYearAndMonth() BEGIN -- 定义参数 declare id int; declare yearMonth varchar(10); declare done INT DEFAULT FALSE; -- 定义游标 declare cur_income cursor for select income_id,date_format(posting_date,'%Y/%m') from output_inco.原创 2021-05-08 16:39:03 · 327 阅读 · 0 评论 -
ORACLE查询锁表记录并释放
--查询锁表记录 select b.owner TABLEOWNER, b.object_name TABLENAME, c.OSUSER LOCKBY, c.USERNAME LOGINID, c.sid SID, c.SERIAL# SERIAL from v$locked_object a,dba_objects b, v$session c where b.object_id = a.object_id AND a.SESSION_ID =c.sid --释放锁表记录 alter sys.原创 2020-09-10 10:02:21 · 251 阅读 · 0 评论