Twice the Owls took the lead with upper-class shots from Etienne Esajas, twice the Millers hit back quickly and then they banished their neighbours from the Carling Cup via a penalty shoot-out.
Wednesday had hit the bar three times and appeared to have victory in their grasp when, three minutes from the end of extra time, Esajas cashed in on a professional foul by Marc Joseph and the defender's sending-off by using the free kick to put his team 2-1 up.
But an equaliser from Reuben Reid in the penultimate minute kept the 10-man Millers alive and ultimately Mark Robins' men were rewarded for a performance full of endeavour.
Wednesday made five changes to the line-up that started last Saturday's 4-1 win against Burnley but will have felt that they were strong enough to win.
Brian Laws brought in Peter Gilbert, Steve Watson, Esajas, Jimmy Smith and Leon Clarke, and rested Sean McAllister, Richard Hinds (ankle knock) and Jermaine Johnson (calf knock) as well as being without the injured Marcus Tudgay and Akpo Sodje.
Clarke headed home an early corner by debut-maker Smith but was harshly penalised for holding.
Watson was first to find the woodwork, with a delicate chip in the seventh minute, and Andy Warrington made a super stop from a deflected shot by Esajas after a great crossfield ball from Burton but straight away, in the 14th minute, the keeper was given no chance by a terrific shot from the Dutch winger from a similar position, driven into the far bottom corner from the left-hand side of the box.
Seven seconds after the restart, the ball was in Wednesday's net. From the kick-off, the ball was knocked back to Pablo Mills, he launched it forward, and the Owls failed to deal with it as Alex Rhodes nipped in to slot the ball home.
Real quality, came from Esajas in the 42nd minute: James O'Connor touched a free kick and from 30 yards the left winger rattled the bar.
Less than three minutes into the second half Esajas cut inside from the left after receiving a good ball from Burton and brought a first-class block from Warrington.
Rotherham switched Rhodes from the left flank to the right, to help full back Mark Lynch to combat Esajas.
A rare long-range shot by Richard Wood floated narrowly wide.
That raised Owls and raised fans' spirits; so did an Esajas corner that was headed over the bar at the far post by Burton when Wood was better positioned behind him.
After Burton was taken off in the 63rd minute, Wednesday paid Rotherham the compliment of changing their system to match the Millers': Clarke became a lone central striker, with support out wide from Esajas and Smith, andSean McAllister came on to stiffen midfield.
The Millers had been awkward opponents who worked hard to try to stifle the Owls, using a central striker, with two pacey wide men, and a central midfield three in which Mills was the anchor man.
Luke Boden took over from Steve Watson in Wednesday's midfield in the 77th minute.
With nine minutes left, the Owls hit the bar for the third time after Smith let fly from 18 yards but they could have gone behind soon afterwards as Sharps beat Wood in the air at the far post and nodded high over.
Just before the end of normal time, Lekaj replaced Smith and went to the left wing, with Esajas switched to the right, and the sub nearly set up a goal early in injury time: his cross was helped on by Boden, and just failed to fall into the unmarked Clarke's path.
Wednesday pushed Boden forward to give Clarke more support but the stalemate continued in the first half of extra time. With 12 minutes of the match left, O'Connor shot wide from 20 yards, and four minutes after that Reuben Reid got past Wood and struck a near post shot from which Grant made a save.
Suddenly Lekaj headed a ball forward and Clarke was breaking clear; Joseph fouled him from behind and got an inevitable red card.
From the free kick 25 yards out, Esajas curled a splendid left-foot shot into Warrington's bottom left-hand corner. That was in the 117th minute. It seemed that victory was Wednesday's. But it wasn't.
Two minutes later, amid desperate pressure from Rotherham, the ball came down off the bar after Danny Harrison's shot, and Reid drove it home.
The shoot-out took place in front of the Kop: Mills scored, Clarke made it 1-1;
Harrison put the Millers 2-1 ahead; Esajas hit the outside of the keeper's right-hand post; Mark Hudson made it 3-1; James O'Connot did not fail, nor did Andy Todd for Rotherham and McAllister for Wednesday.
Reid planted his spot kick into Grant's bottom left-hand corner and the Millers were through, 5-3 on penalties, while the Owls became one of seven Championship clubs to fall at the first hurdle.
CLICK ON THE GREEN PLAY BUTTON ABOVE TO SEE MATCH PICTURESWhat do you think? Post your comments below. READ MORE Football headlinesMore BladesMore OwlsMore SpireitesMore RoversMore RedsMore MillersMore Ice HockeyMore rugby leagueMore rugby unionMore boxingSports columnistsAll sport categories
The full article contains 935 words and appears in Sheffield Star newspaper.