比30號部門任意一人工資高的人信息 為什么查30號部門工資最少的人 不應(yīng)該比最大的人工資高就比任意一個(gè)人都工資高嗎 我想不明白了 誰能幫幫我
2019-11-11
select c.ci_id,wm_concat(s.stu_name) stu_name
from pm_ci c,pm_stu s
where instr(c.stu_ids,s.stu_id)<>0
group by c.ci_id;
from pm_ci c,pm_stu s
where instr(c.stu_ids,s.stu_id)<>0
group by c.ci_id;
2019-09-22
select c.ci_id 學(xué)號, wm_concat(decode(instr(c.stu_ids, s.stu_id), 0, '',s.stu_name) ) 選課列表
from pm_ci c, pm_stu s
group by c.ci_id;
from pm_ci c, pm_stu s
group by c.ci_id;
2019-09-18
1:select c.ci_id cid,s.stu_name sname ,instr(c.stu_ids,s.stu_id)
from pm_ci c,pm_stus s
where instr(c.stu_ids,s.stu_id)<>0;
結(jié)果:select b.cid,wm_concat(b.sname) from (1) b group by b.cid;
from pm_ci c,pm_stus s
where instr(c.stu_ids,s.stu_id)<>0;
結(jié)果:select b.cid,wm_concat(b.sname) from (1) b group by b.cid;
2019-09-16
select a.ci_id,wm_concat(b.stu_name) stu_name from sett.pm_ci a,sett.pm_stu b
where instr(a.stu_ids,b.stu_id)>0
group by a.ci_id
where instr(a.stu_ids,b.stu_id)>0
group by a.ci_id
2019-08-25
select c.ci_id,wm_concat(c.stu_name) stu_name from
2 (select c.ci_id,s.stu_name from pm_ci c ,pm_stu s where instr(c.stu_ids,s.stu_id)<>0) c 當(dāng)做新表
3* group by c.ci_id
2 (select c.ci_id,s.stu_name from pm_ci c ,pm_stu s where instr(c.stu_ids,s.stu_id)<>0) c 當(dāng)做新表
3* group by c.ci_id
2019-08-14
SELECT *
FROM (SELECT rownum r,empno,ename,sal
FROM (SELECT rownum,empno,ename,sal FROM emp ORDER BY sal DESC ) e1
WHERE rownum <=4) e2
WHERE r>=1;
最外面一次取值直接用*就可以了吧
FROM (SELECT rownum r,empno,ename,sal
FROM (SELECT rownum,empno,ename,sal FROM emp ORDER BY sal DESC ) e1
WHERE rownum <=4) e2
WHERE r>=1;
最外面一次取值直接用*就可以了吧
select c.CI_ID,wm_concat(s.stu_name)STU_NAME from
PM_CI c join PM_STU s
on instr(c.stu_ids,s.stu_id)>0
group by c.ci_id;
CI_ID STU_NAME
1 張三,趙六,王五,李四
2 2 張三,趙六
PM_CI c join PM_STU s
on instr(c.stu_ids,s.stu_id)>0
group by c.ci_id;
CI_ID STU_NAME
1 張三,趙六,王五,李四
2 2 張三,趙六
2019-07-26
select t.ci_id, (select wm_concat(STU_NAME) from PM_STU t1
where instr(STU_IDS,t1.stu_id)>0) STU_NAME from PM_CI t
where instr(STU_IDS,t1.stu_id)>0) STU_NAME from PM_CI t
2019-04-16
--答案
select c.ci_id,wm_concat(s.stu_name)
from pm_ci c left join pm_stu s on
instr(c.stu_ids,s.stu_id)>0 group by c.ci_id;
select c.ci_id,wm_concat(s.stu_name)
from pm_ci c left join pm_stu s on
instr(c.stu_ids,s.stu_id)>0 group by c.ci_id;
2019-04-03