Naturally, the dealer's computer will only have records for things that were done at any Mercedes dealer.
They can run a report called a VMI (vehicle master inquiry) that will list all of the recall / warranty work that was done on the car. If the wiring harness and / or head gasket were replaced under warranty, then they would show up.
If they were not replaced in this fashion, then those items would not be listed on the VMI.
If the owner of the vehicle had these items replaced at a dealer, then certainly they would have a record of it, but they usually won't share this information with you unless you own the car. The service and repair records belong to the owner of the car when the work was performed.
If the dealer owns the car at this time on their lot, then I see no reason why they won't share the complete service and repair history of the vehicle.
There is a way to check the wiring harness to see if it's been replaced. It is somewhere in the archives if you'd like to experiment with the search function.
2001 E430, Bourdeaux Red, Oyster interior.
1973 280SE 4.5, 170,000 miles. 568 Signal Red, Black MB Tex. "The Red Baron".