關(guān)鍵是老師是站在學(xué)生的角度教學(xué),所以容易聽(tīng)懂,就好像你給剛識(shí)字的小朋友講1+1=2,你認(rèn)為很好懂,那是你站在大人角度看,你的站在小朋友角度講,這樣他更容易懂
2017-06-08
最新回答 / 慕仰9027661
scope=spfile 僅僅更改spfile里面的記載,不更改內(nèi)存,也就是不立即生效,而是等下次數(shù)據(jù)庫(kù)啟動(dòng)生效。有一些參數(shù)只允許用這種方法更改scope=memory 僅僅更改內(nèi)存,不改spfile。也就是下次啟動(dòng)就失效了?scope=both 內(nèi)存和spfile都更改不指定scope參數(shù),等同于scope=both.
已采納回答 / qq_孫長(zhǎng)志_0
因?yàn)閙ysql屬于第三方數(shù)據(jù)庫(kù)軟件,并不是跟一樣。所以,當(dāng)你要用是需要加載mysql的包才能用
2017-06-07
loop
fetch emp_cursor into cempno,csal ;
exit when (totalSal + csal*0.1) > 50000 or emp_cursor%notfound;
update emp set sal=sal*1.1 where empno=cempno;
countsum:=countsum+1;
totalsal:=totalsal+csal*0.1;
end loop;
fetch emp_cursor into cempno,csal ;
exit when (totalSal + csal*0.1) > 50000 or emp_cursor%notfound;
update emp set sal=sal*1.1 where empno=cempno;
countsum:=countsum+1;
totalsal:=totalsal+csal*0.1;
end loop;
2017-06-06
loop
exit when (totalSal + psal*0.1) > 50000;
fetch emp_cursor into cempno,csal ;
exit when emp_cursor%notfound;
update emp set sal=sal*1.1 where empno=cempno;
countsum:=countsum+1;
totalsal:=totalsal+csal*0.1;
end loop;
exit when (totalSal + psal*0.1) > 50000;
fetch emp_cursor into cempno,csal ;
exit when emp_cursor%notfound;
update emp set sal=sal*1.1 where empno=cempno;
countsum:=countsum+1;
totalsal:=totalsal+csal*0.1;
end loop;
2017-06-06
已采納回答 / 仲夏4155273
不需要判斷是否排序,因?yàn)樗诙x光標(biāo)的時(shí)候,已經(jīng)使用了排序保存,這樣操作的光標(biāo)中的員工和員工工資就是按照從低到高進(jìn)行的.
2017-06-03
set serveroutput on
declare
cursor cemp(dno number) is select ename from emp where empno=dno;
pename emp.ename%type;
begin
open cemp(10);
LOOP
fetch cemp into pename;
exit when cemp%notfound;
dbms_output.put_line(pename);
end loop;
close cemp;
end;
/
為啥我沒(méi)有結(jié)果
declare
cursor cemp(dno number) is select ename from emp where empno=dno;
pename emp.ename%type;
begin
open cemp(10);
LOOP
fetch cemp into pename;
exit when cemp%notfound;
dbms_output.put_line(pename);
end loop;
close cemp;
end;
/
為啥我沒(méi)有結(jié)果
2017-06-01
光標(biāo)又叫做游標(biāo),代表了一個(gè)結(jié)果集。好比是jdbc中的Result Set集
2017-06-01
代碼段三:
close emp_cursor;
dbms_output.put_line('漲工資人數(shù) 工資總額');
dbms_output.put_line(rpad(countsum,8,' ')||' '||rpad(totalsal,8,' '));
end;
close emp_cursor;
dbms_output.put_line('漲工資人數(shù) 工資總額');
dbms_output.put_line(rpad(countsum,8,' ')||' '||rpad(totalsal,8,' '));
end;
2017-05-28