The entire Haruhi series is famously randomly scrambled, so neither it's airing order nor their episode number follow the chronological order of events.
You then have a series of one-shot stories from the books (and one original episode contributed by the creator of Full Metal Panic!) that get scattered throughout, as there wasn't enough content for a full season, and it would be weird to have the climax occur mid-season.