Let me rephrase the question
Lets assume I have a ant directory "org.apache.ant_" at different location in 2 diffrent version of weblogic server
In weblogic 5 it is in A/B/org.apache.ant.1.3/bin
In weblogic 6 it is A/B/C/org.apache.ant.1.4/bin
I know it exists in Directory A but trying to write a script inside A where it exists soo my script should find for org.apache.ant.x.y and return A/B/org.apache.ant.1.3 or A/B/C/org.apache.ant.1.4