【发布时间】:2016-08-24 04:20:21
【问题描述】:
select id, first_name, family_name, eq_id,
date_of_birth, gender, indigenous, eal_d,
atsi, icp, disability_category,
(select raw_score
from path_maths_term0 as T0
where T0.eq_id=S.eq_id and year=2011
) as raw_score_2011term1,
(select raw_score
from path_maths_term0 as T0
where T0.eq_id=S.eq_id and year=2011
) as raw_score_2011term1,
(select scale_score
from path_maths_term0 as T0
where T0.eq_id=S.eq_id and year=2011
) as scale_score_2011term1,
(select percentile
from path_maths_term0 as T0
where T0.eq_id=S.eq_id and year=2011
) as percentile_2011term1,
(select stanine
from path_maths_term0 as T0
where T0.eq_id=S.eq_id and year=2011
) as stanine_2011term1,
class
from student_details as S
where S.school_id ="SCH00001" and S.class = " 5B"
【问题讨论】:
-
任何正文都可以帮助我了解在哪里更改此查询
-
在查询中使用
LIMIT 1 -
非常感谢它的工作!
-
你为什么使用子查询和查询表
path_maths_term05 次,你可以使用连接在 1 个镜头中完成?
标签: php mysql codeigniter mysqli codeigniter-3