Complicated list query episodes and seasons

I am wondering if it is possible to do this query without creating an additional table…
essentially what I have is a list of shows, but think of them as episodes on a tv series, say, and one of the columns is show_season.
I want to know if there would be a way to list like

Season 5-heading
-ep1 name date link etc
Season 4-heading

Ideally I don’t want seasons table, so that when the client adds a ‘season 6’ it will automatically be put at the top. Also curious about doing the same thing just divided by year instead of season based on the already existing show_date.

What I know of mysql and php right now is pretty basic so I don’t even know whether this is really possible.
If it would require a relational database, would there be a way to automate it that’s fairly straightforward?


You would handle with two columns in your table as suggested
Season and Episode

you would handle the layout you are looking for in your front end application.

Ok yeah, I know that… I guess I should be posting in php instead. Thought it’d be query related, but I don’t even know where exactly the line between php and mysql gets drawn

think of php (or any front end application) as displaying or tidying and displaying the data.

mysql (or any database) is used for manipulating the data to give you the result set needed, though not necessarily in the final format you are going to use it.