All of my dogs have been acquired between the ages of 18 months and 4 years of age and they all have disavowed any knowledge of being housebroken and peed in the house for awhile. I've found that you have to go thru the housebreaking procedure just like you would for a puppy. Marking (and you can tell the difference) has to be treated as unacceptable behavior and can be harder to break in an older dog that you adopt, depending on his background.
'If you find a way to enjoy the ride, it doesn't really matter where you end up'
5 GSDs at the gate: Katie, Iroc, Red, River, Jake