where crsmain_pk1 = @COURSE and title like cast(@i as varchar) + '주차%' and cnthndlr_handle = 'resource/x-bb-folder'

-- 코스 > 콘텐츠 영역 > 각 주차별 폴더 > 강의자료, 영상

update bblearn..course_contents

set start_date = @DEFAULT_WEEKDAY,

end_date = dateadd(n, 10079, @DEFAULT_WEEKDAY),

available_ind = 'Y',

reviewable_ind = 'N'

from BBLEARN..course_main

where crsmain_pk1 = @COURSE

and title like cast(@i as varchar) + '주차%' and not cnthndlr_handle = 'resource/x-bb-folder' and not cnthndlr_handle = 'resource/x-bb-assignment' and not cnthndlr_handle = 'resource/x-bb-asmt-test-link'

-- 코스 > 콘텐츠 영역 > 각 주차별 폴더 > 출석퀴즈 또는 과제

update bblearn..course_contents

set start_date = @DEFAULT_WEEKDAY,

end_date = dateadd(n, 10079, @DEFAULT_WEEKDAY),

available_ind = 'Y'

from BBLEARN..course_main

where (crsmain_pk1 = @COURSE and title like cast(@i as varchar) + '주차%' and cnthndlr_handle = 'resource/x-bb-assignment') or (crsmain_pk1 = @COURSE and title like cast(@i as varchar) + '주차%' and cnthndlr_handle = 'resource/x-bb-asmt-test-link') or

(crsmain_pk1 = @COURSE and title like cast(@i as varchar) + '주차%' and cnthndlr_handle = 'resource/x-bb-courselink')

update bblearn..eud_item

set due_date = dateadd(n, 10079, @DEFAULT_WEEKDAY)

from bblearn..course_contents cc

where cc.crsmain_pk1 = @COURSE and crs_contents_pk1 = cc.pk1 and cc.title like cast(@i as varchar) + '주차%' and cnthndlr_handle = 'resource/x-bb-asmt-test-link'