process dependency

how to find all the processes associated with a given process in unix,is there any command for this.

What does "associated with" mean?

for example: if the httpd is using mysql how to see this relationship. given that pid of httpd is known how to get pids of the related processes.

use ptree in Solaris & Linux