随笔分类 -  数据库

摘要:一 竖表转横表 1. 学生表成绩表-竖表 2. 查询数据 select * from student; 3. 想要将数据显示为横表, 即如下形式 数据显示为横表 sql语句: select name as '姓名', max(case subject when '语文' then result el 阅读全文
posted @ 2021-08-06 17:05 青城杂文录 阅读(988) 评论(0) 推荐(0)
摘要:MySQL 字符串截取函数:left(), right(), substring(), substring_index()。还有 mid(), substr()。其中,mid(), substr() 等价于 substring() 函数,substring() 的功能非常强大和灵活。 1. 字符串截 阅读全文
posted @ 2021-05-19 14:08 青城杂文录 阅读(853) 评论(0) 推荐(0)
摘要:oracle数据库操作 一:解锁Scott/tiger 用户(locked)alter user scott account lock; --锁定alter user scott account unlock; --解锁alter user scott identified by tiger; -- 阅读全文
posted @ 2016-03-16 15:57 青城杂文录 阅读(318) 评论(0) 推荐(0)