in reply to File::DosGlob

Or, you could do it the old-fashioned way...
opendir(DATADIR, "files/$department") or die "Invalid directory!"; @duplicate = readdir(DATADIR); closedir(DATADIR); foreach $item (@duplicate) { if ($item eq "files/$department/$number.txt") { $go_sub = 'yes'; last; } }
I have usually used glob() myself, but I read recently that it's not the best way to do it, that it has some quirks on different platforms. As for what those quirks are, I haven't a clue.

Update: However, in reading your code, it looks as though you may be simply trying to verify the presence of a file in that directory... perhaps you just want the -e operator, to see if the file exists:
$go_sub = "yes" if -e "files/$department/$number.txt";


Hot Pastrami