string s = " from dual union all "; s = s.Trim().TrimEnd("union all".ToCharArray());结果是"from d"
http://www.cnblogs.com/carekee/articles/2094731.html