利用正则表达式进行字段拆分
WITH t AS (SELECT 'abc/def/ghi' AS x FROM dual)SELECT regexp_substr(x,'[^/]+',1,LEVEL) AS wordFROM tCONNECT BY LEVEL<=LENGTH(x)-LENGTH(REPLACE(x,'/',''))+1;
perl文本文件处理
最近需要提取出文本文件中某几列的数据,简单写了一下脚本:use strict;my $read_file = "1.txt";my $write_file = "2.txt";open my ($fhin), '<', $read_file or die "Can't open file: $!";open my ($fhou...