extension length matters for del command????

Discussion forum for all Windows batch related topics.

Moderator: DosItHelp

Post Reply
Message
Author
trey
Posts: 2
Joined: 31 Oct 2008 14:31

extension length matters for del command????

#1 Post by trey » 31 Oct 2008 14:44

I'm not a DOS expert, but I just accidentally deleted some files in a way that I didn't know was possible... Perhaps an example speaks for itself:

C:\temp\testing>echo asdf > file.tx

C:\temp\testing>echo asdf > file.txt

C:\temp\testing>dir
Directory of C:\temp\testing

10/31/2008 03:27 PM <DIR> .
10/31/2008 03:27 PM <DIR> ..
10/31/2008 03:27 PM 7 file.tx
10/31/2008 03:27 PM 7 file.txt
2 File(s) 14 bytes
2 Dir(s) 22,652,850,176 bytes free

C:\temp\testing>del *.tx

C:\temp\testing>dir
Directory of C:\temp\testing

10/31/2008 03:27 PM <DIR> .
10/31/2008 03:27 PM <DIR> ..
10/31/2008 03:27 PM 7 file.txt
1 File(s) 7 bytes
2 Dir(s) 22,652,850,176 bytes free

C:\temp\testing>echo asdf > file.txt2

C:\temp\testing>dir
Directory of C:\temp\testing

10/31/2008 03:27 PM <DIR> .
10/31/2008 03:27 PM <DIR> ..
10/31/2008 03:27 PM 7 file.txt
10/31/2008 03:27 PM 7 file.txt2
2 File(s) 14 bytes
2 Dir(s) 22,652,850,176 bytes free

C:\temp\testing>del *.txt

C:\temp\testing>dir
Directory of C:\temp\testing

10/31/2008 03:28 PM <DIR> .
10/31/2008 03:28 PM <DIR> ..
0 File(s) 0 bytes
2 Dir(s) 22,652,850,176 bytes free

C:\temp\testing>



What gives???
TIA.

DosItHelp
Expert
Posts: 239
Joined: 18 Feb 2006 19:54

#2 Post by DosItHelp » 01 Nov 2008 15:02

trey, confirmed - strange :?

Post Reply