It’s so amazing that most of those developers out there have got no idea how to create a virtual path on their machines. If you are in the same bot, read on.
There are some circumstances that you need to access a given long path (e.g., “C:Program FilesMicrosoft SQL ServerMSSQL.1MSSQLData”) frequently and therefore you’ve to browse to the directory over and over again during the daytime work. You could easily associate such a long path with a drive letter using the subst in the command line of the console window. By typing the “subst /?” on the command line, you’ll get the syntax of the command:
Associates a path with a drive letter.
SUBST [drive1: [drive2:]path]
SUBST drive1: /D
drive1: Specifies a virtual drive to which you want to assign a path.
[drive2:]path Specifies a physical drive and path you want to assign to a virtual drive.
/D Deletes a substituted (virtual) drive.
Type SUBST with no parameters to display a list of current virtual drives.
Therefore, the following line assigns the drive letter “d” to above mentioned path:
subst d: “C:Program FilesMicrosoft SQL ServerMSSQL.1MSSQLData”
to remove the virtual path, try the following command:
subst d: /D
If you do not like the console window (for whatever reason), you may try the Visual Subst GUI utility.
That’s all for now, folks!
Circle up with me on Google+