while read DAY TIME A B C D E TRASM RETR DR; do echo $DAY ${TIME%:*} "NEWNAME$((++CNT))" $TRASM $RETR $DR; done < file3 2015-02-10 10:00 NEWNAME1 trasm:1266245958 retrasm:439137 dropped:36504 2015-02-10 10:00 NEWNAME2 trasm:1339998535 retrasm:86120 dropped:47549 2015-02-10 10:00 NEWNAME3 trasm:1362335738 retrasm:84469 dropped:48248 2015-02-10 10:00 NEWNAME4 trasm:1362335738 retrasm:84469 dropped:4824 2015-02-10 10:00 NEWNAME5 trasm:1362335738 retrasm:84469 dropped:4824