i've a string
$DIR=/u/user/NDE/TEST_LOGS/20110622_000005_TEST_11_HD_120/HD/TEST_11_HD_120/hd-12
i need to extract string from 2011.... i.e i need it as 20110622_000005_TEST_11_HD_120 as matched string, and in turn i need to split values 20110622_000005_TEST_11_HD_120 into two. i.e 20110622_000005 in one variable and rest into other.
string, may start with any thing, like.. /a/b/c/d/201106....., but it always has time stamp, i.e 20110622_00 ... etc.. and end with /HD