[ic] TAX rounding incorrect...

Mike Heins interchange-users@icdevgroup.org
Sat Oct 19 09:26:00 2002


Quoting Rene Hertell (interchange-users@hertell.com):
> > > Hi,
> > >
> > > I've setup tax system based on VAT, Country and tax category...
> > >
> > > and have setup the tax category as followed:
> > >
> > > default = 20% , food = 8.5%
> > >
> > > The problem is now that 20% tax works fine but with 8.5% it
> > does not... it
> > > rounds and calculates the tax wint 8%...
> > > 0.08
> > >
> > > And the problem is because I use comma as decimal separator...
> > >
> > > So how to setup the tax category with "comma"... like 8,5% ???
> > >
> >
> > Maybe the problem is just because it calculates all with 2 digits... so it
> > multiplies all with 0.08 instead of 0.085..
> 
> 
> Did you try to change your price to include commas instead of points?
> Vijeeth did that, and got his truncated values to display correct.

No -- Saso's problem is that locale is screwed up on his machine.

I recommend simplification:

	1. Try the tax stuff with no sl_SLO locale, only en_US, and
           see if it works.

	2. If it does, add this to the end of catalog.cfg:


	    Locale sl_SLO  currency_symbol  "(the symbol)"
	    Locale sl_SLO  default 1
	    Locale C

I believe the problem is that Perl is running with a base locale of sl_SLO,
which we don't want. We need it to run with a base locale of C.

I suggest you try this for starting up Interchange:

	export LC_ALL=C
	bin/interchange -restart


-- 
Mike Heins
Perusion -- Expert Interchange Consulting    http://www.perusion.com/
phone +1.513.523.7621      <mike@perusion.com>

Fast, reliable, cheap.  Pick two and we'll talk.  -- unknown