Derby County ended their pre-season campaign with a 2-1 loss despite an impressive performance against UEFA Champions League bound TSG 1899 Hoffenheim at Pride Park Stadium.

The visiting side had to until the hour mark to make the breakthrough, which came through Lukas Rupp, but although the German side bossed possession, the Rams had their chances.

Bradley Johnson saw a penalty superbly saved by Oliver Baumann, before Matej Vydra levelled matters by seizing on a stray back pass to round the goalkeeper and slip the ball into the back of the net.

Hoffenheim, however, responded immediately and hit back two minutes later to seal the win through Sandro Wagner’s well-executed effort from the edge of the box.

Nevertheless, as a workout, Derby have so many positives to build upon for their Sky Bet Championship opening game against Sunderland next Friday.

This was Derby’s seventh and final pre-season fixture before the beginning of the 2017/18 campaign, and the first 45 minutes developed into a cagey affair.

The visitors had the better chances – opportunities created through fine possession play.

Ádám Szalai and Serge Gnabry both had efforts saved by Scott Carson from the edge of the box, whilst the latter had another cleared off the line.

The Rams had to wait until just before the interval to register their best chance.

After a bit of ingenuity on the right, Johnny Russell managed to advance the ball up the field quickly before putting in a dangerous cross for Chris Martin, who saw his goal-bound shot cleared desperately – preventing Derby from breaking the deadlock.

Derby were far better in the second half and looked far more threatening.

Another cagey beginning in the second half followed but it wasn’t long before Gary Rowett’s side upped the intensity and this caused problems once again for the visiting side – Martin going the closest again, but he saw his angle reduced after rounding the ‘keeper.

It took an hour for the deadlock to be broken and it was Hoffenheim who managed to do so against the run of play after Szalai’s initial saved shot was converted in by Rupp from close range.

Rowett’s side had the opportunity to react perfectly less than 10 minutes later after they were awarded a penalty but a firm hand from Baumann prevented Bradley Johnson from bringing the Rams back level.

From the off, though, it was a game that looked as if it could go either way and on 80 minutes Vydra made a perfect example of that after a poor back-pass allowed him to find space outside of the box and slot coolly past Bauman who was off his line.

Unfortunately, being back on level terms was not to last for Rowett’s side as after less than three minutes of it being 1-1, a superbly struck ball from Wagner on the edge of the box saw the ball find its way into the bottom left corner.

That was how it finished, but the Rams came away with a great deal of credit – finishing their pre-season campaign with a strong performance to build on ahead of their opening day trip to the Stadium of Light.

Derby County: Carson, Wisdom, Keogh, Davies, Forsyth (Olsson, 78), Huddlestone, Butterfield (Bryson, 46), Johnson (Bennett, 71), Russell (Anya, 71), Weimann (Vydra, 71), Martin (Nugent, 71)

Substitutes not used: Mitchell, Roos, Pearce, Blackman, Hanson,

TSG 1899 Hoffenheim: Bauman, Kaderabek (Schulz, 72), Bicakcic (Wagner, 60), Rupp (Zulj, 72), Zuber (Posch, 72), Amiri (Kramaric, 46), Uth (Polanski, 60’), Hubner (Geiger, 60), Vogt (C), Szalai (Nordtveit, 60), Gnaby (Demirbay, 46)

Substitutes not used: Kobel

Attendance: 11,406