Basic Join Part 2
Coddy SQL 여정의 기초 섹션에 포함된 레슨 — 72개 중 44번째.
조인(Join)은 우리가 생성한 테이블에서도 사용할 수 있습니다. 중첩된 테이블을 조인으로 결합하려면 중첩된 쿼리를 이름으로 식별하기 위해 AS를 추가해야 합니다.
예를 들어:
SELECT table1.col1, table2.col2, ...
FROM table1, (SELECT * FROM table) AS table2
WHERE table1.id = table2.id챌린지
쉬움사용 가능한 테이블 및 컬럼:
<strong>grades</strong>:<strong>course_id</strong>,<strong>student_id</strong>,<strong>grade</strong><strong>students</strong>:<strong>id</strong>,<strong>name</strong>
각 학생별로 평균 성적을 계산하고, 각 학생의 이름과 평균 성적을 반환하세요.
컬럼명은 student, grade로 지정하세요.
평균은 소수점 둘째 자리까지 반올림하고, 결과를 평균 성적 기준 오름차순으로 정렬하세요.
직접 해보기
이 레슨에는 짧은 퀴즈가 포함되어 있습니다. 레슨을 시작해 문제를 풀고 진행 상황을 기록하세요.
기초의 모든 레슨
4More Keywords
The IN keywordThe BETWEEN keywordThe LIKE keywordThe AS keywordRecap - Cellphone Models2Conditions
Conditions BasicsThe AND keywordThe OR keywordThe NOT keywordMultiple Conditions CombinedParenthesisBooleans5Arithmetic Operations
Mathematical OperatorsMathematical ColumnsThe Modulo OperationThe ROUND() Function3Specific Return Format
Null valuesSort Results Part 1Sort Results Part 2Recap - Cyber Security FirmLimit number of recordsRecap - Vehicle Factory6Intro Challenges
Recap - Parliamentary ElectionRecap - Police Criminal ArrestRecap - Bar Beverage ContainerRecap - Engineer new columns