Pulling data from SQL, and writing to a text file

前端 未结 7 1166
广开言路
广开言路 2021-01-07 01:28

I am trying to pull data from SQL, and then write it to a text file. This does that, to an extent, but it only pulls 1 from the table, which reads test:test<

7条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2021-01-07 01:53

    echo "select concat(user,':',pass,'
    ') from table order by fc desc" | mysql

    I prefer to do this kind of thing in bash ;)

提交回复
热议问题