Re: how to substitute ',' by '.' within awk script

From: Jef Lee (jef.lee@ITVISION.COM.AU)
Date: Thu Jan 23 2003 - 20:16:58 EST


I think you LANG setting or NLS setting must be affecting this. I have read
somewhere that in some places the decimal point is displayed as a comma.
Perhaps in the shell script that runs the Awk script, you could put in:

LANG=C

which is my setting. I get the 0.25 result not 0,25 as you do.

Jef...

-----Original Message-----
From: Jarzombek, Svend [mailto:Svend.Jarzombek@ALCOA.COM]
Sent: Thursday, 23 January 2003 11:09 PM
To: aix-l@Princeton.EDU
Subject: how to substitute ',' by '.' within awk script

Content of $4 is 0.500
$4 *= 0.5 results in 0,25 and leads to an additional value in VALUES clause
of INSERT statement (SQL).
0.25 is needed as result to INSERT into database correctly.

I start walking through the archives, but maybe someone can point to the
right direction meanwhile.

Thanks in advance

Svend



This archive was generated by hypermail 2.1.7 : Wed Apr 09 2008 - 22:16:31 EDT