Hi!
I am scripting a solution that requires two characters to be replaced in a string that appears in a file (with other unrelated strings) and I'm struggling to figure-out a routine that will satisfy the requirement.
The string is always consistent, and is in the form;
INV_20070430131255_H062849B.DAT
It appears in a file as the 8th record on the first line of numerous lines. Each record is delimited with a "|" character.
The string after "INV" is the date, month, day, hour and minute and then millisecond (in this case "55"). After this string, there is another underscore, followed by a string that always begins with "H" and ends with ".DAT".
What I am trying to do is replace just the two characters for the "55" with "zz" These are always the 13th & 14th characters in the long numeric string after "INV_"
I'm struggling to find a placeholder routine that will zero-in on just those two digits.
Any assistace with this would be gratefully received.
recl
I am scripting a solution that requires two characters to be replaced in a string that appears in a file (with other unrelated strings) and I'm struggling to figure-out a routine that will satisfy the requirement.
The string is always consistent, and is in the form;
INV_20070430131255_H062849B.DAT
It appears in a file as the 8th record on the first line of numerous lines. Each record is delimited with a "|" character.
The string after "INV" is the date, month, day, hour and minute and then millisecond (in this case "55"). After this string, there is another underscore, followed by a string that always begins with "H" and ends with ".DAT".
What I am trying to do is replace just the two characters for the "55" with "zz" These are always the 13th & 14th characters in the long numeric string after "INV_"
I'm struggling to find a placeholder routine that will zero-in on just those two digits.
Any assistace with this would be gratefully received.
recl