...But the writers took great care to establish that Scotty's survival method had little to do with normal transporting. The diagnostics mode apparently doesn't involve the usual interaction between the constituent particles of the transportee, but puts them to a stasis of some sort. So Scotty isn't awake, doesn't suffocate and doesn't starve.
Ahhhhhh. Technobabble to the rescue, again!