Using TR in a different way omits the commas and decimal point, sign, and any other funny characters. To do this, you swap the roles of the translate table and the string being translated.
----- Original Message ----- From: "IBM Mainframe Assembler List" To: Cc: Sent:Mon, 17 Oct 2016 16:24:18 -0400 Subject:Re: converting character to packed The TR command would leave all the non-numeric characters in the data, translated as you specified, so you'd have to have a technique to pass through the result to remove them. A TRT instruction would help you find the non-numeric characters, but in this case it would be considerably slower in execution than the character by character loop approaches suggested. If the original manually-entered data is not edited as it's entered, there could be many other characters besides "$",",","." and EBCDIC numeric characters in it. That's something TRT could check for. Gary Weinhold Senior Application Architect __________ On 2016-10-17 15:11, [email protected] wrote: Won't a TR followed by a PACK do this? Email sent using Dodo Webmail
