Hello I'm trying to do something like this but it wont work, can you guys tell me help me out?
/usr/bin/mysql -B -r -h ******** -u******* -p****** -D***** \
-e'SELECT `username`, `uid`, `gid`, `homedir` FROM `some_table`)' | \
awk '{print $1":x:"$2":"$3"::"$4":/usr/sbin/nologin"}' >> /tmp/file1 ;
awk '{print $1":"$5":13753:0:99999:7:::"}'>>/tmp/file2
Changing ";" to "&&" doesn't work either. Both file1 and file2 is created, but only file1 contains data. So basically what I want to do is using the same variables for two commands