When comparing old diesels to old coal power plants the power plants win by being more efficient but both belch out a lot of pollution. They also have the advantage of burning coal, a fuel which is available in abundance and does not need as much processing as crude oil does to be used in diesel engines.
When comparing old diesels to modern coal power plants this is true at an even higher level since those modern power plants filter out fly ash and are more efficient.
When comparing modern diesels to old coal-fired power plants the diesels win by being less polluting and possibly on terms of efficiency.
Modern diesels versus modern coal power plants goes to the power plants again since these win on terms of efficiency - especially when using combined heat & power - over the diesels.