infor.com
concierge
infor u
developer portal
documentation central
customer center
Posts
Categories
Groups
ERPs
CSD
FSM/HRT
LN
M3
Syteline/ CSI
Hubs
Developer
Healthcare
Hospitality
Public Sector
Onboarding
Release Center
CloudSuites
Aerospace & Defense (LN)
Automotive (LN)
Chemicals (M3)
Corporate (FSM/HRT)
Distribution (Sx.e/CSD)
Distribution Enterprise (M3)
Engineering & Construction (LN)
Fashion (M3)
Food & Beverage (M3)
Healthcare (FSM/HRT)
Industrial (Syteline/CSI)
Industrial Enterprise (LN)
Manufacturing (M3)
Public Sector (FSM/HRT)
Solutions
Supply Chain Management (SCM)
Human Capital Management (HCM)
Events
Groups
User Groups
Your Groups
About
Email Community Support
Infor News
Migrated Forums
Home
Clovertech
Clovertech Archive
Read Only Archives
Cloverleaf
Cloverleaf
Find a specific string format in a segment
Dustin Sayes
Howdy,
I want to search a line of HL7 and find anything that reflects a specific format.
Like this:
#In this example the SSN is 011-22-3348
#I need to be able to find anything that matches a SSN format, store it to a variable and ultimately put it back in the message as xxx-xx-3348
#How does one scan, using TCL, to find a specific format?
#I have been sing the string scan $var1 $var2, but no luck yet.
PID|1||M000000115^^^YVMC.TEST5.66^MR^YVMC~011-22-3348^^^YVMC.TEST5.66^SS^YVMC
Find more posts tagged with
Clovertech
Comments
Keith McLeod
How about something like:
regsub -all -- {d{3}-d{2}-(d{4})} $msg {xxx-xx-1} newmsg
Dustin Sayes
Perfect.
Thank you!