He said passengers pulled the emergency alarm to stop the train as soon as the fire broke out and passengers jumped out of the car.
Y S Rajasekhara Reddy, the chief minister for Andhra Pradesh, reaffirmed that an electric failure could have led to the fire on the Secunderabad-Kakinada train.
In New Delhi, Lalu Prasad, the railways minister, said the fire was "very sad and unfortunate" and that compensation would be offered to the injured and the next of kin of each victim according to The Hindu,
India's national newspaper.
The state government also announced a compensation package for the families of those killed.
The fire began in one of the coaches at 1.15am (2015 GMT) between Tallapusalapalli and Mehboobabad stations, near Kesamudram, South Central Railway spokesman P Krishnaiah said.
Passengers were fast asleep when the fire began, reports suggested.
Prasad set up an inquiry to determine the exact cause of the fire. "Until now, no proof of sabotage or use of explosive has come to our notice," he said.