inblog logo
|
goho
    SQL문제풀기

    [프로그래머스/SQL]흉부외과 또는 일반외과 의사 목록 출력하기

    gov's avatar
    gov
    Dec 04, 2024
    [프로그래머스/SQL]흉부외과 또는 일반외과 의사 목록 출력하기
    Contents
    문제풀이

    문제

    notion image
    notion image

    풀이

    date_format(칼럼명, '%Y-%m-%d') - 지정한 형태로 출력
    cs 이거나 gs인 경우라 OR
    select dr_name, dr_id, mcdp_cd, date_format(hire_ymd, '%Y-%m-%d') hire_ymd from doctor where mcdp_cd = 'cs' or mcdp_cd = 'gs' order by hire_ymd desc, dr_name asc;
    Share article

    goho

    RSS·Powered by Inblog