awk embedded script issue (unexpected character '\')
问题 I use an embedded awk code in a shell script: I have some variable assignments at the BEGIN part of it: \ BEGIN { FS=","; OFS=","; service_not="false"; end_of_line="\n"; is_setup_gps="false"; \ \ a=6378137.0 ; \ b=6356752.3142 ; \ f=(a-b)/a ; \ e=sqrt(f*(2-f)) ; \ } \ \ So I need '\' at the end of each line (to have an entire awk script embedded in .sh). BUT: for the lines: a=...; b=...; f=...; the '\' causing errors...: mawk: 57: unexpected character '\' Why? UPD: Embedding of awk in the