I'm looking to utilize something to the effect of this code:

Code:
ps -ef | grep sc_serv | grep -v grep | awk '{print $2}' > sc_serv.pid
cat sc_serv.pid
3447
3449
The first id it spits out is the screen process that I run the sc_serv command under, and that's fine, because killing that process is really what I want. Killing the second will just produce nothing.

What I'd really like is...