标签:
?"检查IP格式是否正确
??DATA:?ld_matchcnt?TYPE?i.
??FIND?REGEX?‘((2[0-4]\d|25[0-5]|[01]?\d\d?)\.){3}(2[0-4]\d|25[0-5]|[01]?\d\d?)‘
??????IN?clientip?IN?CHARACTER?MODE
??????MATCH?COUNT?ld_matchcnt.
??IF?ld_matchcnt?=?0.
????set_symsg?‘E‘?‘00‘?‘001‘?‘客户端IP格式错误:‘?clientip?‘‘?‘‘.
????RAISE?ip_format_error.
??ENDIF.
? ?
匹配中文
2015年4月13日
9:05
? ?
data:?l_regex?type?string.
? ?
? ?
l_regex?=?‘[^a-zA-Z0-9]‘.
? ?
find?first?occurrence?of?regex?l_regex?in?l_str.
if?sy-subrc?=?0.
??message?‘包含中文‘?type?‘S‘.
else.
??message?‘不包含中文‘?type?‘S‘.
endif.
标签:
原文地址:http://www.cnblogs.com/rootbin/p/4463312.html