String split方法在忽略参数大小的情况下取得String[]的小技巧
				     摘要: select * from tableA union select * from tableB
    要根据关键字把两个查询语句分解出来,即得到
   select * from tableA 和 select * from tableB
 但因为这个是SQL语句,union关键字不区分大小写的,所有sql语句有这些情况:
 select * from tableA UNION select * from tableB
 select * from tableA UnIOn select * from tableB
 select * from tableA UNiON select * from tableB
 ……
所以单单用这样的语句:String sql2[]=sql.split(" union ");
是分解不出子语句的。
  
阅读全文
				
					posted @ 
2008-05-04 10:13 蒋家狂潮 阅读(2236) | 
评论 (5)  编辑