我有一份名为<代码>sqlfile的案文,内容如下:
a.sql
b.sql
c.sql
d.sql
What I want is that to store them in variables and then print using for
loop.
But here I get only d.sql
in the output of the script.
文字:
#!/bin/bash
while read line
do
files=`echo $line`
done < /home/abdul_old/Desktop/My_Shell_Script/sqlfile
for file in $files
do
echo $file
done