On Wed, 05 Feb 2003 11:04:34 +0600, Debraj Bhattacharyya wrote:

> I am facing a problem .In one script ,it asks the user to enter a
> filename ,where the whole path can also be entered.For Example :
> 
> Enter the FILENAME : /usr/bin/xyz.sql
> 
> My question is how to separate the directory path from the filename
> ,store it in different variables and then go to that particular
> directory to look for the file ?

What have you tried so far ?

To separate filenames and directories,
I would suggest to use the module
File::Basename from CPAN.

Storing in different variables seems not to be too hard.

To go into a directory look to
perldoc -f chdir


Greetings,
Janek

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to