select s_id, s_f_name, s_l_name, s_roll_no, s_class,
SUM(mid_1_english + mid_2_english)/2 as mid_english,
SUM(mid_1_mathematics + mid_2_mathematics)/2 as mid_mathematics,
semester_final_english,
semester_final_mathematics,
SUM((mid_1_english + mid_2_english)/2 + semester_final_english) as total_english,
SUM((mid_1_mathematics + mid_2_mathematics)/2 + semester_final_mathematics) as total_mathematics,
SUM((mid_1_mathematics + mid_2_mathematics)/2 + (mid_1_english + mid_2_english)/2 + semester_final_mathematics + semester_final_mathematics) as total
from elaborate_term_result_sheet
group by s_f_name, s_l_name
order by s_roll_no;
在运行这个创建的查询之后,它确实显示输出,但是值有点波动
中英文+中英文=中英文
数学+数学=数学
中英文+期末英文=总英文
期中数学+期末数学=总数学
合计=英语合计+数学合计
1条答案
按热度按时间ktca8awb1#
给出正确输出的唯一变化是
此查询输出的快照