Traveling from Delhi to Mysore is a two days two nights affair by train; of course you can travel from Delhi to Mysore by flight (via Bangalore or Chennai), even that probably takes a day due to the transit though flight time is much shorter.
There is one direct train from Delhi to Mysore, and many options if you are planning a break journey. A sleeper class ticket from Delhi to Mysore cost you about Rs600 (approx $13) in an express train.
Swarna Jayanthi Express ( Train No 12782) is a weekly train that leaves from H Nizamuddin station of Delhi every Monday and arrives at Mysore Junction (see Mysore Railway Station ) on Wednesday covering a cross country distance of about 2600km (1615 miles) between Delhi and Mysore. In the reverse direction Swarna Jayanthi Express ( Train No: 12781) leaves Mysore Junction on the Fridays and reaches H Nizamuddin on Sundays.
Bangalore city, located some 140km (3 hours) northeast of Mysore city, is well connected with Delhi with frequent rail connections. From Bangalore to Mysore you can travel by train or bus services, which are quite frequent. Get down at Bangalore City Junction railway station. You can get trains to Mysore from this station. Or you can walk down to the KSRTC bus terminal that is located just across the railway station, for bus connection to Mysore. Hiring a cab from Bangalore is another option.
Delhi to Bangalore takes anything from 33 hours to 46 hours depending on the train. There are about 3 daily trains in each direction between Bangalore and Delhi.
Karnataka Express (Train No 12628) is a daily train between Delhi and Bangalore. Also it starts from New Delhi railway station compared to the other trains to Bangalore that start from H Nizamuddin.
The fastest (and expensive!) train between Delhi and Bangalore is the Bangalore Rajdhani Express ( Train No.12430 & 12494). This takes about 33 hours between Bangalore and Delhi. This too operates daily on either directions. Train No: 12493 & 12429 operate in the reverse direction. A 3AC ( the lowest class in the train) ticket cost about Rs2200 (approx. $50) while the highest class (1AC) ticket cost about Rs4700 ($105), almost matching the economy class flight ticket price.
The next fastest after Banglore Rajdhani Express is the Karnataka Sampark Kranti Express (Train No: 12650). This leaves from H Nizamuddin daily except on Wednesdays and Fridays. Also this train terminates at Yesvantpur Junction of Bangalore. In the reverse direction ( Train No: 12649) the train operate on all days except on Tuesdays and Thursdays.
The Yesvantpur Sampark Kranti Express (Train No: 12630) operates from H Nizamuddin Wednesdays and Fridays to Yesvantpur Junction. The return train ( Train No:12629) operates on Tuesdays and Thursdays. In that was this pair compliments the pair 12650/12649.
The Coimbatore bound Kongu Express (Train No:12648) from H Nizamuddin travels via Bangalore. This is a weekly train (Wednesdays). In the reverse direction (Train No:12647) Kongu Express leaves Bangalore City Junction on Sundays.
Apart from these, there are many train options depending on where you break the journey and the route you plan for a connection train. For example there are direct trains from Mumbai to Mysore and also to Bangalore.
As there could be changes, please check the details with the Indian Railways website for the current and accurate train details.