How do I define a particular dir in PATH variable and then unset that dir

How do I define a particular dir in front of PATH variable and then run some job and then at the end of job SET the PATH variable to original?

in a script, WILL something like this work:

ORIG_PATH=$PATH
export PATH=/dir1/dir2:$PATH

RUN SOME JOBS .....

unset PATH
EXPORT PATH=$ORIG_PATH

Also is there a way to not UNSET the path and look for particular dir and take it out from PATH variable??

if you define a value for PATH inside a script, the value is only changed as far as the process running the script is concerned. "Nobody" else is ever affected. I think this may be the simple answer to your question. Changes to a child environment variable are NOT reflected in the parent process' same environment variable.

There is no command called EXPORT; it is lowercase: export

There is (see http://cfaj.freeshell.org/shell/scripts/path-funcs-sh\), but it is not necessary, since the change only affects the current script and its children.