mysql dump to file and fetch it instead of reading from stdout