日期:2014-05-16 浏览次数:20691 次
H20100520RM D10000289 4999005962 +000074388601+000052345912+000000354951488 D18834804 4999005244 +000000076168+000000076168+000000000000000 [color=#FF6600]D19479732 8630147526 +000001000110+000001000110+000000000260880 D35028000 4900005911 +042645985553+042606672253+000000076412526 [/color]D69000008 4904006485 +000013110899+000013110899+000000577693219 D69000016 4904006501 +000502371438+000502371438+000000525968999 T7
19479732 35028000
$ sed -n '1p' acc_detl > accRemove $ grep -f accounts acc_detl >> accRemove $ echo T`grep -f accounts acc_detl |wc -l` >> accRemove $ cat accRemove H20100520RM D19479732 8630147526 +000001000110+000001000110+000000000260880 D35028000 4900005911 +042645985553+042606672253+000000076412526 T2
------解决方案--------------------
$ sed -n '1p' acc_detl > accNew $ sed '1d;$d' acc_detl |grep -v -f accounts >> accNew $ echo T`sed '1d;$d' acc_detl |grep -v -f accounts |wc -l` >> accNew $ cat accNew H20100520RM D10000289 4999005962 +000074388601+000052345912+000000354951488 D18834804 4999005244 +000000076168+000000076168+000000000000000 D69000008 4904006485 +000013110899+000013110899+000000577693219 D69000016 4904006501 +000502371438+000502371438+000000525968999 T4