摘要: 平台有个需求要导入信息到MYSQL..分析了下,写了个脚本,几分钟搞定。。。while(){ @tmp=split(/\t/,$_); @xieyi=split(/\//,$tmp[1]); if($xieyi[1] eq 'tcp'){ if($tmp[3]=~m/^\#(.*)/){ print "portname:$tmp[0] port_number:$xieyi[0] port_text:$1 \n"; } }}sub db_insert{ my $name=shift; my $text=shift; my $port=shift; m... 阅读全文
posted @ 2013-10-31 17:45 墨迹哥's 阅读(284) 评论(0) 推荐(0) 编辑