這麼簡單的sql問題看看文檔就知道了。
sql reference
http://gigabase.idi.ntnu.no/oradoc/nav/docindex.htm

解决方案 »

  1.   


        学科明细表
    学科编号(char(10));
    学科名称(char(20));
    学科加权系数(number(3,2));
    学科注册状态(char(1))。create table table_name   (xsbh   char(10),xkmc  char(20),...);
    看下SQL语句。。
      

  2.   

    4.在上述已创建数据库的基础上,要求创建一名为FundTSP表空间,并在FundTSPBIA表空间上创建一用户FundUSR。写出创建的SQL脚本。关键是这道题,不知道怎样用脚本创建用户,而且和表关联
      

  3.   

    create tablespace FundTSP datafile 
    'd:\oradata\FundTSP_1.ora' size 512M, 
    'd:\oradata\FundTSP_2.ora' size 512M, 
    default storage (initial 128K next 2M pctincrease 0);create user FundUSR identified by aaa;grant create session,create table to FundUSR;
      

  4.   

    4.在上述已创建数据库的基础上,要求创建一名为FundTSP表空间,并在FundTSPBIA表空间上创建一用户FundUSR。写出创建的SQL脚本。关键是这道题,不知道怎样用脚本创建用户,而且和表关联
    ---------------------------------------
    create tablespace FundTSP datafile 
    'd:\oradata\FundTSP_1.ora' size 512M, 
    'd:\oradata\FundTSP_2.ora' size 512M, 
    default storage (initial 128K next 2M pctincrease 0);create user FundUSR identified by aaa default tablespace FundTSP; grant create session,create table to FundUSR;
      

  5.   

    谢谢 ruyuezhang(ruyue) 和 hdkkk(diablo2) !!!
    你们写的是Oracle里面的语句吗?可否把最后一题的后三小题也做一下,万分感激!!!小弟是初学者……
      

  6.   

    hehe,楼主是要做什么课程设计吗?
      

  7.   


     创建表空间的语句中 initial和next参数最好一致,以减小表空间
     碎片.
      

  8.   

    谢谢 leecooper0918(PajeroFans) ,我建的表是这样的detail(sid(学号),cid(课程号),cscore(课程的分数))
    studentinfo(sid(学号),sname(姓名),sindex(名次),save(平均分),ssum(总分))
    course(cid(课程号),cname(课程名字),jiaquan(加权))不考虑加权 ,求总分和平均分可以用这样的语句吗?
    select detail.sid,sname,sum(cscore),avg(cscore) 
    from studentinfo left join detail on studentinfo.sid=detail.sid 
    group by detail.sid order by avg(cscore) desc
      

  9.   

    谢谢 leecooper0918(PajeroFans) ,这是一道课后题,做出来就行了.
      

  10.   

    select detail.sid,sname,sum(detail.cscore*course.jaiquan),avg(cscore) from studentinfo join detail 
    on studentinfo.sid=detail.sid 
    join course 
    on detail.cid=course.cid 
    group by detail.sid 
    order by avg(cscore)这样可以吗?高手们,看看可不可以?
    真的很急!!!
      

  11.   

    select detail.sid,sname,sum(detail.cscore*course.jaiquan),avg(cscore) from studentinfo join detail 
    on studentinfo.sid=detail.sid 
    join course 
    on detail.cid=course.cid 
    group by detail.sid 
    order by avg(cscore)就是这样!