BEGIN{ while(getline x < F){ split(x,words,","); out=words[1]","words[2]","words[3]","words[4]; print out } close(F); }