SQL SQL未能提取HKDSE 中文及英文

本文由 chautc 在 2020-07-23 發表於 "WebSAMS 討論區" 討論區

  1. 10004315

    chautc
    Expand Collapse

    文章:
    58
    讚:
    0
    可以把下列SQL 包括提取 HKDSE 中文及英文的成績總分嗎?
    謝謝!

    Select
    a.examyear,
    b.subjcode 'Subject Code',
    b1.DSESUBJGROUPNAME_ENG||' ('||b1.DSESUBJGROUPNAME_CHI||')' 'Subject Name',
    a.classcode,
    a.classno,
    a1.regno,
    a1.ENNAME,
    a1.CHNAME,
    a1.sex,
    b.subjgrdlvl 'Subject Grade'
    from tb_hke_dsecandinfo a
    left outer join tb_stu_student a1
    on a.suid=a1.suid and a.stuid=a1.stuid
    left outer join tb_hke_dsesubjresult b
    on a.suid=b.suid and a.schcode=b.schcode and a.candno=b.candno and a.examyear=b.examyear and b.subjcode NOT IN ('A010', 'A020')
    left outer join
    (select distinct SUID, EXAMYEAR, EXAMCODE, DSESUBJGROUPCODE, DSESUBJGROUPNAME_ENG, DSESUBJGROUPNAME_CHI
    from tb_hke_regexamsubjgrp group by SUID, EXAMYEAR, EXAMCODE, DSESUBJGROUPCODE, DSESUBJGROUPNAME_ENG, DSESUBJGROUPNAME_CHI) b1
    on b.suid=b1.suid and b.examyear=b1.examyear and b1.examcode='DSE' and b.subjcode=b1.DSESUBJGROUPCODE
    left outer join tb_hke_dsesubjcompresult c
    on b.suid=c.suid and b.schcode=c.schcode and b.candno=c.candno and b.examyear=c.examyear and b.subjcode=c.subjcode
    left outer join tb_hke_regexamsubjcomp c1
    on c.suid=c1.suid and c.examyear=c1.examyear and c1.examcode='DSE' and c1.dsesubjcomptype='RESULT' and c.subjcode=c1.dsesubjgroupcode
    where a.examyear=?
    order by 2,4,5
     
  2. 58521906

    edb-catherinewschan
    Expand Collapse

    文章:
    124
    讚:
    0
    你好,

    在CDR也有抽取HKDSE成績的SQL, 你看看能否抽取中英文成績

    網上校管系統 — 常用SQL參考庫 https://www.websams.edb.gov.hk//sql/html/SQL_Q&A.html#
    學生成績 (下載)

    III. 有關學生公開試成績資料:

    1. 抽取HKDSE各科公開考試成績。
    2. 抽取香港考試及評核局 香港中學文憑試成績
     
    #2 edb-catherinewschan, 2020-07-25
    Last edited: 2020-07-25