MEDITECH Reports, MEDITECH NPR Reports, NPR Report Writing, NPR Report Writer, NPR Report, MEDITECH Reporting, MEDITECH Report MEDITECH Reports, NPR Reports, NPR Report Writing, NPR Report Writer, MEDITECH NPR

Friday, January 27, 2006

Regular Magic Expressions

To strip all non-numerics from a string:
(STRING'~(D(255):48_("0123456789")_(D(255):70)))^STRING

To strip all non-alphas from a string:
(STRING'~(D(255):65_"ABCDEFGHIJKLMNOPQRSTUVWXYZ"_(D(255):6)_"abcdefghijklmnopqrstuvwxyz"_(D(255):5)))^STRING

To upper case a string:
Magic: (STRING~$L.TO.U)^STRING
CS: STRING@Trl2u^STRING

To lower case a string:
(STRING~$U.TO.L)^STRING

0 Comments:

Post a Comment

Links to this post:

Create a Link

<< Home