Database iterative sql syntax

problem description

to get data for all semester weeks, use SQL syntax

the environmental background of the problems and what methods you have tried

related codes

4 attributes, academic year semester, start time, end time, start week, end week

what result do you expect? What is the error message actually seen?

want all dates in 1-23 weeks, such as
2017-2018-1 2018-3-31 2018-4-06 1
2017-2018-1 2018-4-06 2018-4-13 2
2017-2018-1 2018-4-13 2018-4-20 3
2017-2018-1 2018-4-20 2018-4-27 4
2017-2018-1 2018-4-27 2018-5-35
.
2017-2018

different database solutions are fine. I have tried to use tmp table to add sequences and carry out internal association.
but I don"t want to use ordinal lists

.
Apr.12,2021

can be solved by stored procedures and executed in a loop

SELECT Term, BeginDate, DATE_ADD (current date, INTERVAL 7 DAY), current number of weeks FROM term_info
current date = DATE_ADD (current date, INTERVAL 7 DAY)
current number of weeks + 1

results are saved to temporary table

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b36288-3439f.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b36288-3439f.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?