Shankar,
Depending on what version of mySQL you're running, you can use the source switch to execute:
mysql>. '/path/to/filename.sql'
Remember that you don't need the semi-colon at the end of the statement and if you're running on Win32 to either use the Unix-style forward slashes in your path statement or escape-slashes if you use the Win32 backslash. Running the switch \h (or ?) from the mySQL command prompt will give you a list of supported command line switches. Hope this helps.
Cheers,
Geoff A. Virgo