Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have some program in many places (it is the java command).. I am starting this command from CMD. the problem is, I need to know exactly the path of the java command being run..

(If you know unix, I need a command such as which ).


share|improve this question
up vote 2 down vote accepted

Does Which for Windows help?

share|improve this answer
great thanks!!! – Muhammad Hewedy Oct 29 '10 at 12:53

There is no need to install WHICH, as Windows has a native command that does the same things, called WHERE.

It is a native command on Vista onwards, but can be added from the Windows Server 2003 Resource Kit on earlier versions of Windows.

share|improve this answer
You can make an which alias to where if you want. – paradroid Nov 4 '15 at 15:50

There is not an exact equivalent of "Unix's which" in Windows, but that does not mean there is no solution ;) Check out the following link:

Which for Windows

share|improve this answer

Because time ago I could not found an adequate alternative of "which" command for windows, I implemented a simple replacement in python featuring also partial matches of command names:

Hope you find it useful :)

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .