Search Results

Search: Posts Made By: tdouty
3,812
Posted By tdouty
Thank you. I did have to keep the commas so added...
Thank you. I did have to keep the commas so added that to the command.
3,812
Posted By tdouty
Awesome! That seemed to work. Thank you so much! ...
Awesome! That seemed to work. Thank you so much!

I used it this way:
cat all_major_codes.txt | awk -F, '{gsub(/[[:space:]]/,"_",$1)} 1' > new_file
3,812
Posted By tdouty
Replace spaces with underscores up to first comma but not after the comma
I have a comma delimited file of major codes and descriptions. I want to replace all occurrences of spaces with underscores up to the first comma (only in the first field), but not replace spaces...
Showing results 1 to 3 of 3

 
All times are GMT -4. The time now is 02:19 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy