sed -n ''478142,919384''p alert_sid.log |grep "add datafile" >t.txt
----------------------------------------------------------------------
#!/usb/bin/ksh
cd /home/oracle/admin/sid/bdump
dd=`date +%Y%m%d`
riqi=`date |cut -c1-10`
year=`date | awk '{print $6}'`
hang=`grep -nE ^"$riqi".*"$year"$ alert_sid.log|head -1|cut -d: -f 1`
sed -n ''"$hang",$''p alert_sid.log|grep ORA- >file.txt
sed -n 筛选数据(从行到行)
原创
©著作权归作者所有:来自51CTO博客作者mb646da62f0d7e4的原创作品,请联系作者获取转载授权,否则将追究法律责任
提问和评论都可以,用心的回复会被更多人看到
评论
发布评论
相关文章
-
读取数据库中的m行到n行的数据
--读取数据库中的m行到n行的数据--sql...
SQL 读取m行到n行的数据 sql 读取数据 oracle -
厦门行,从BRT到地铁
BRT不改轻轨,准备建地铁了
职场 休闲 地铁 厦门