Re: Sales Tax Algorithm
- From: Logan Shaw <lshaw-usenet@xxxxxxxxxxxxx>
- Date: Sun, 04 Mar 2007 00:59:26 -0600
The Night Blogger wrote:
I'm looking for the Algorithm for calculating the sales tax on a sles
invoice for the US and Canada
Hello there,
I just came across your blog while googling about sales tax info in
North America
Blog? Whose blog? You've posted to the newsgroup comp.programming.
It's not a blog at all but a Usenet newsgroup.
I'm writting a time tracking software, which will enable people to
record time spent on a given task and then generate a sales invoice
based on the billable hours.
I'm aware that there's a different sales %tax rate% for each US state,
There are 50 states, but it is more complicated than just a single
rate for each state. In Texas, where I live, the state sets a
rate (which is 6.25%) and then gives the localities (such as counties,
cities, and transit agencies) the authority to add to it. The
state sets a maximum additional amount that the locality can add
to the 6.25%, so that the total sales tax can range between 6.25%
and 8.25% depending on local rules. Since there are 254 counties
and even more cities than that, and since the combination of county
laws and city laws may interact differently depending on what part
of the county you're in (it would be possible to be inside a county
but outside the city limits), in theory there could be thousands
of different tax rates depending on your location. There are, at
least, thousands of different combinations of authorities that
can set (part of) the tax rate.
Of course there are other variations as well based on geography.
Non-profit organizations (such as charities and churches) are
exempt from sales tax, and I believe resellers are exempt from
it too since it is intended to be a tax on retail sales. I
have made purchases in the past where the vendor required a
copy of my company's reseller certificate (issued by the state?)
and would then not charge us sales tax, since we were going to
resell the purchased items to a customer of ours.
Also, it may depend on the item. When consumers buy unprepared
food (food that is not ready to eat, such as uncooked meat), the
food is not taxed (at least in Texas). But other types of food
are taxed. Some other products, such as cars, are taxed at
different rates.
Because of all these complications, most software would simply
allow the user to determine the appropriate tax rate, enter that,
and use it in the calculation. Since some line items would be
taxable and others would not (and since some items might be
taxable at different rates from each other), the usual approach
would be to set up a short table of tax rates, then allow the
user to associate a given rate with a particular line item or
class of line items.
1/ If I'm a Californian based company which issue a sales invoice to a
Massachussets based company, does sales tax should be calculated for
the invoice ? If sales tax should appears which rate should I put on
the sales line (The MA or CA rate?)
I'm not a lawyer or accountant, so I can't answer this question
authoritatively, but from what I understand, the Constitution would
not allow either the State of California or the State of Massachusetts
to charge sales tax in this case. The reason is that this would be
interstate trade, which the states do not have the power to regulate.
However, if the company is based in California but makes a sale to a
customer in Massachusetts and has an office *in* Massachusetts (no
matter what its function is), then the transaction might be subject
to sales tax.
2/ Imagine I've got a sales invoice which contains those 3 lines :
(The quantity are hours of work, and the description are services)
_______________________________________________________
Qty Description Unit Price Amount Amount inc Tax
8 Programming 100 800 ???
1 Support Call 100 100 ???
1 Design Spec 100 100 ???
_______________________________________________________
TOTAL 1000
2.a : Should I add the tax rate on each line to work out the Amount
Inc TAX per sales invoice line or should I only add it to the $1000
TOTAL ?
Generally speaking, the actual calculation of the tax is done one
the entire total, taking into account which line items are taxable
(and at what rate) and which aren't. I *believe* this is in order
to avoid round-off error. Otherwise, there would be too much
temptation to price things so that the round-off error reduces the
taxes. Or, maybe it's just traditional and uses less space on
paper. :-)
2.b : Could you take my example and calculate the tax on this simple
invoice ?
Often, labor is not taxable at all. But, sometimes it is. In most
cases, I think programming labor is not subject to sales tax at all,
but again I'm not a lawyer or tax accountant.
3/ Does any other kind of tax should appears on a sales invoice ?
governmental ? federal ? provincial (for Canada) ??
Well I just hope calculating sales tax for North America (USA &
Canada) is not a too complex process
Once you know the rates, it's not too complicated to calculate it,
but knowing the rates is not easy. Luckily, it's probably not
necessary either. For one thing, nobody expects your software to
know the rates for invoicing labor (at least I think they don't),
and further, it would in many cases be easier for the person to
enter the tax rate than it would be for them to answer all the
questions your software would need answered in order to properly
compute it.
- Logan
.
- Follow-Ups:
- Re: Sales Tax Algorithm
- From: robertwessel2@xxxxxxxxx
- Re: Sales Tax Algorithm
- References:
- Sales Tax Algorithm
- From: The Night Blogger
- Sales Tax Algorithm
- Prev by Date: Re: What compiler would you recommend?
- Next by Date: Re: Musings on uniqueness
- Previous by thread: Sales Tax Algorithm
- Next by thread: Re: Sales Tax Algorithm
- Index(es):
Relevant Pages
|