Horje
awk use string as field separator Code Example
awk use string as field separator
Just use function split in awk command to split a line into an array 'a'
using a choosen string as delimiter as for example ", " in next use case:
echo "hi, bye, hey" | awk '{split($0,a,", "); print a[3],a[2],a[1]}'
Or you could also do next:
echo "a, b, c" | sed 's/, /,/g' file.txt | awk -F ',' '{print $1 $2 $3}'




Shell

Related
delete merge branch git Code Example delete merge branch git Code Example
git supprimer branche origin Code Example git supprimer branche origin Code Example
bash mkdir Code Example bash mkdir Code Example
bash for file in directory Code Example bash for file in directory Code Example
copy everything in a directory linux Code Example copy everything in a directory linux Code Example

Type:
Code Example
Category:
Coding
Sub Category:
Code Example
Uploaded by:
Admin
Views:
9