利用简单的shell脚本,生成有规律的导入文件

shell脚本,生成有规律的导入文件

=============================================

#!/bin/bash


n1=2342020000000

while [ $n1 -ne 2342020000999 ]  #当n1的值不等于2342020000021 


do #执行


echo "+"$n1"|23401220000000914" >> qhd.txt #输出"+" n1的值|23401220000000914


n1=$(($n1+1))


done


=============================================

输出##################################

cat  qhd.txt
+2342020000000|23401220000000914
+2342020000001|23401220000000914
+2342020000002|23401220000000914
+2342020000003|23401220000000914
+2342020000004|23401220000000914
+2342020000005|23401220000000914
+2342020000006|23401220000000914
+2342020000007|23401220000000914
+2342020000008|23401220000000914
+2342020000009|23401220000000914
+2342020000010|23401220000000914

你可能感兴趣的:(利用简单的shell脚本,生成有规律的导入文件)