How to add a symbolic link in Windows 7

I wanted several times to do, like on my linux installation, a symbolic link. For people who’s don’t know I’ll explain a bit.
When you read some tutorials about mysql, for example, you will probably find something like:
mysql -u root …..
You need to go to mysql folder to do this command.
The symbolic link allows you to directly write on your prompt « mysql » and the command line will make the link between your command and the mysql.exe. (or any other .exe)

To do this you have to:

– Go on Start Menu
– Seek for Computer
– Right click on it, then Properties
– Choose Advanced system settings
– Go on Advanced tab
– Click on Environment Variables…
– Edit the Path variable
– Add the folder where you have your mysql (for me it’s: C:\wamp\bin\mysql\mysql5.5.24\bin\ so I add:
;C:\wamp\bin\mysql\mysql5.5.24\bin\

Don’t forget the ; before and the backslash at the end.
Then ok, close the window.

Now open a prompt and you should be able to write mysql command everywhere.

If you prefeir to choose another word like sqlvar, you can do as well:
mklink name repository

For our example:
mklink sqlvar C:\wamp\bin\mysql\mysql5.5.24\bin\mysql.exe