Results 1 to 6 of 6
  1. #1
    Join Date
    Jul 2006
    Posts
    144
    Plugin Contributions
    0

    Default VAT error message (1366 Incorrect decimal value)

    Hi !

    I got an error that I didn't receive before and I have no idea why it's here now. The message I receive is;

    1366 Incorrect decimal value: '35,6' for column 'order_tax' at row 1
    in:
    [INSERT INTO shop_orders (customers_id, customers_name, customers_company, customers_street_address, customers_suburb, customers_city, customers_postcode, customers_state, customers_country, customers_telephone, customers_email_address, customers_address_format_id, delivery_name, delivery_company, delivery_street_address, delivery_suburb, delivery_city, delivery_postcode, delivery_state, delivery_country, delivery_address_format_id, billing_name, billing_company, billing_street_address, billing_suburb, billing_city, billing_postcode, billing_state, billing_country, billing_address_format_id, payment_method, payment_module_code, shipping_method, shipping_module_code, coupon_code, cc_type, cc_owner, cc_number, cc_expires, date_purchased, orders_status, order_total, order_tax, currency, currency_value, ip_address)
    VALUES ('3', 'Kenneth', '', 'Street 13', '', 'Nynäshamn', '149 41', 'ta bort', 'Sweden', '08-123 456', 'kenneth##########################', '1', 'Kenneth', '', 'Street 13', '', 'Nynäshamn', '149 41', 'ta bort', 'Sweden', '1', 'Kenneth', '', 'Street 13', '', 'Nynäshamn', '149 41', 'ta bort', 'Sweden', '1', 'Förskottsbetalning', 'moneyorder', 'Per produkt (Postgång)', 'item', '', '', '', '', '', now(), '2', '178', '35,6', 'SEK', '1.00000000', '127.0.0.1 - 213.114.123.123')]

    The error part is 'order_tax' and '35,6'. This is the swedish VAT (moms), if you redraw 20% from 178, the price, you will have 35,6. Can someone please help me ?

    Using XP, ZC 1.0.3.2 and the swedish language pack 1.0.3.1. I hope you have all the information you need to help me to solve this strange message...

  2. #2
    Join Date
    Jul 2006
    Posts
    144
    Plugin Contributions
    0

    Default Re: VAT error message (1366 Incorrect decimal value)

    I just changed back to engligh language and it works super. So it seems to have something to do with the swedish language pack. Anyone know what it could be ? I really need help here...

  3. #3
    Join Date
    Jul 2006
    Posts
    144
    Plugin Contributions
    0

    Default Re: VAT error message (1366 Incorrect decimal value)

    Sience noone seems to be able to help me with this problem, I re-installed ZC, entered a couple of products and tried to order them without any problems.

    So I edited english.php in /include/language and changed all the relevent text into swedish. I tried again to order some items and now I have the same problem, after step 3, when I'm trying to confirm the order, I receive the same SQL error msg.

    Please help, anyone ???

  4. #4
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: VAT error message (1366 Incorrect decimal value)

    1. What are your settings for SEK in your currencies area?
    2. If you change "Decimal Point: ," to "Decimal Point: ." does that change anything?
    3. Admin->Configuration->My Store->Switch To Default Language Currency.... is this set to false or true? What happens if you change it?
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  5. #5
    Join Date
    Jul 2006
    Posts
    144
    Plugin Contributions
    0

    Default Re: VAT error message (1366 Incorrect decimal value)

    Hi there !

    Thanx for trying to help me to solve this problem.

    1. Title: Swedish SEK
    Code: SEK

    Symbol Left:
    Symbol Right: :-

    Decimal Point: .
    Thousands Point: ,
    Decimal Places: 0

    Last Updated:
    Value: 1.00000000

    Example Output:
    30:- = 30:-

    2. I changed the 'dot' from , to . and tried them both on both Decimal Point and Thousands Point with the same result, unfortunatly...

    3. If I change this to True, I have to choose SEK for it to show the swedish currency and when I come to my shopping cart, it shows $ for some reason. If I continue and come to the final step, I receive the same error SQL msg. So I changed it back to False.

    Would you like to see my english.php ? The only things that I've changed are the text that shows on my shop, changed it to swedish, it's very strange that this english.php doesn't work but the original works..

    I hope you can help me solve this problem. If there is anything else you want me to try, just let me know !!

    /Typhoon

  6. #6
    Join Date
    Jul 2006
    Posts
    144
    Plugin Contributions
    0

    Default Re: VAT error message (1366 Incorrect decimal value)

    Finally, I found the problem... It has nothing to do with the swedish translation, it has to do with @setlocale(LC_TIME, 'en_US.ISO_8859-1') !!

    If you have this, it will show "Nya produkter för July", "New products for July". But I want it to say juli instead of July so I found in a couple of places here in this forum that if you change this row, @setlocale(LC_TIME, 'en_US.ISO_8859-1') in english.php (or swedish.php) to
    @setlocale(LC_ALL, 'sv_SE.ISO_8859-1','Swedish') (using XP) it will say juli, and it does.

    However, this row made the SQL error, I don't know why.

    So I experemented a little bit and in the end, if I have LC_TIME instead of LC_ALL, everything works fine, now I can buy products again.

    I have no idea what this LC_ALL and LC_TIME does or what the difference is, but if anyone know, please tell me. I hope now that nothing else strange will appear somewhere else ...

    Thanx, DrByte, for trying to help me !

    /Typhoon

 

 

Similar Threads

  1. v154 Issue with Authorize.net AIM updating table - error 1366 incorrect integer value
    By inklingsolutions in forum Built-in Shipping and Payment Modules
    Replies: 48
    Last Post: 29 Dec 2016, 09:09 PM
  2. Replies: 2
    Last Post: 22 Jun 2013, 03:48 AM
  3. 1366 Incorrect integer value Problems with MySQL 5 strict-mode
    By Max70 in forum Discounts/Coupons, Gift Certificates, Newsletters, Ads
    Replies: 13
    Last Post: 10 Dec 2009, 07:11 PM
  4. Replies: 4
    Last Post: 14 Jan 2009, 11:45 AM
  5. 1366 Incorrect string value: 'zone_name'
    By technologist in forum Installing on a Windows Server
    Replies: 2
    Last Post: 9 Jul 2008, 04:17 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR