Resolve a Variable

Hi

I have a variable which is a path ie:

UBERROR=/cobwrk/mchr/prodsup/ub/wrk/../error
is there anyway I can get the output of an echo to read:

#echo $UBERROR
/cobwrk/mchr/prodsup/ub/error
instead of
#echo $UBERROR
/cobwrk/mchr/prodsup/ub/wrk/../error

Many thanks!

$ UBERROR=/cobwrk/mchr/prodsup/ub/wrk/../error
$ UBERROR=`echo "${UBERROR}" | sed 's!wrk/../!!'`
$ echo ${UBERROR}
/cobwrk/mchr/prodsup/ub/error

Cheers
ZB

Cheers ZB

But I have a lot of these to resolve and didnt want to have to sed out each of them in turn....