Search Results

Search: Posts Made By: shanneykar
15,025
Posted By bartus11
awk -F"|" '{$2=gensub(".*\\(.+...
awk -F"|" '{$2=gensub(".*\\(.+ ([^)]+)\\).*","\\1",1,$2);print $1,$2}' file
15,025
Posted By bartus11
awk -F"|" '{print $1}' input
awk -F"|" '{print $1}' input
15,025
Posted By frans
shell
If your value is in a variable, the shell builtin can:~$ S="15:29:15 28.08.2010|SCHEDULE: Started program POSG1"
~$ echo ${S%|*}
15:29:15 28.08.2010
15,025
Posted By agama
Try: awk -F "|" '{print $1}'...
Try:

awk -F "|" '{print $1}' <inputfile
2,643
Posted By alister
If you don't want a trailing newline, remove...
If you don't want a trailing newline, remove "\\n". If you don't want it left justified, remove the "-". If you don't want a 100 character wide string, change the "100" to suit your needs.
printf...
2,643
Posted By Corona688
echo assumes the -e is a commandline...
echo assumes the -e is a commandline parameter(echo does indeed take -e on some systems, see man echo) and uses it instead of echoing it. To tell echo that the following string contains no...
2,643
Posted By alister
printf %s\\n "$p"
printf %s\\n "$p"
Showing results 1 to 7 of 7

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