我有这个:
var blockRegEx = new Regex("(proc sql;)(.*?)(quit;)", RegexOptions.IgnoreCase |
RegexOptions.Multiline);
但它仅在字符串位于单行时才有效。
例如:
proc sql;
create table xtr as
select
midsu_client_id,
prodt_cd,
confmt_ind,
maj_diag_categ,
mbr_num,
pay_amt format=comma16.2
from cr_data.rptng
where &acctnum
and gl_postg between "&date_1" and "&date_2"
;
quit;