R4MR4M MemberComments: 2350 Received thanks: 361 Member since: April 2014 edited February 26

Bei einem Kunden haben wir plötzlich seit mitten in der Nacht tonnweise solcher Fehlermeldungen:

PDOException: SQLSTATE(22003): Numeric value out of range: 1690 BIGINT UNSIGNED value is out of range in '(`sw_dust`.`availableVariant`.`laststock` * `sw_dust`.`availableVariant`.`instock`)' in /vendor/doctrine/dbal/lib/Doctrine/DBAL/Connection.php:907 Stack trace:
#0 /vendor/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(907): PDOStatement->execute()
#1 /vendor/doctrine/dbal/lib/Doctrine/DBAL/Query/QueryBuilder.php(206): Doctrine\DBAL\Connection->executeQuery('SELECT product....', Array, Array)

Ist ein SW 5.6.4. Die Fehlermeldung kommt teilweise beim Listung oder bei der Suche.

Answers

  • ShyimShyim MemberComments: 1018 Received thanks: 413 Member since: May 2015

    Kannst du mal schauen was der Höchstwert von laststock und instock in s_articles_details ist?

     

    Thanked by 1R4M
  • R4MR4M MemberComments: 2350 Received thanks: 361 edited February 26 Member since: April 2014

    Ist jetzt schwer nachvollziehbar, denn bei welöchen Artikel soll ich schauen. Mal ist instock größer laststock, mal ist es umgekehrt. Aber ich habe hier auch ein utopisches Query was Fehler erzeugt:

    ... product.metaTitle as __product_metaTitle, product.keywords as __product_keywords, product.changetime as __product_changetime, product.pricegroupID as __product_pricegroupID, product.pricegroupActive as __product_pricegroupActive, product.filtergroupID as __product_filtergroupID, product.crossbundlelook as __product_crossbundlelook, product.notification as __product_notification, product.template as __product_template, product.mode as __product_mode, product.main_detail_id as __product_main_detail_id, product.available_from as __product_available_from, product.available_to as __product_available_to, product.configurator_set_id as __product_configurator_set_id, productAttribute.id as __productAttribute_id, productAttribute.articleID as __productAttribute_articleID, productAttribute.articledetailsID as __productAttribute_articledetailsID, productAttribute.attr1 as __productAttribute_attr1, productAttribute.attr2 as __productAttribute_attr2, productAttribute.attr3 as __productAttribute_attr3, productAttribute.attr4 as __productAttribute_attr4, productAttribute.attr5 as __productAttribute_attr5, productAttribute.attr6 as __productAttribute_attr6, productAttribute.attr7 as __productAttribute_attr7, productAttribute.attr8 as __productAttribute_attr8, productAttribute.attr9 as __productAttribute_attr9, productAttribute.attr10 as __productAttribute_attr10, productAttribute.attr11 as __productAttribute_attr11, productAttribute.attr12 as __productAttribute_attr12, productAttribute.attr13 as __productAttribute_attr13, productAttribute.attr14 as __productAttribute_attr14, productAttribute.attr15 as __productAttribute_attr15, productAttribute.attr16 as __productAttribute_attr16, productAttribute.attr17 as __productAttribute_attr17, productAttribute.attr18 as __productAttribute_attr18, productAttribute.attr19 as __productAttribute_attr19, productAttribute.attr20 as __productAttribute_attr20, productAttribute.dreisc_seo_url as __productAttribute_dreisc_seo_url, productAttribute.dreisc_seo_title as __productAttribute_dreisc_seo_title, productAttribute.dreisc_seo_title_replace as __productAttribute_dreisc_seo_title_replace, productAttribute.dreisc_seo_breadcrumb as __productAttribute_dreisc_seo_breadcrumb, productAttribute.dreisc_canonical_link as __productAttribute_dreisc_canonical_link, productAttribute.dreisc_robots_tag as __productAttribute_dreisc_robots_tag, productAttribute.dreisc_facebook_description as __productAttribute_dreisc_facebook_description, productAttribute.dreisc_twitter_description as __productAttribute_dreisc_twitter_description, productAttribute.dreisc_facebook_image as __productAttribute_dreisc_facebook_image, productAttribute.dreisc_twitter_image as __productAttribute_dreisc_twitter_image, productAttribute.nimbits_extrabadge_text1 as __productAttribute_nimbits_extrabadge_text1, productAttribute.nimbits_extrabadge_color1 as __productAttribute_nimbits_extrabadge_color1, productAttribute.nimbits_extrabadge_text2 as __productAttribute_nimbits_extrabadge_text2, productAttribute.nimbits_extrabadge_color2 as __productAttribute_nimbits_extrabadge_color2, productAttribute.nimbits_extrabadge_text3 as __productAttribute_nimbits_extrabadge_text3, productAttribute.nimbits_extrabadge_color3 as __productAttribute_nimbits_extrabadge_color3, productAttribute.nimbits_extrabadge_image1 as __productAttribute_nimbits_extrabadge_image1, productAttribute.nimbits_extrabadge_image2 as __productAttribute_nimbits_extrabadge_image2, productAttribute.nimbits_extrabadge_image3 as __productAttribute_nimbits_extrabadge_image3, productAttribute.dk_order_one as __productAttribute_dk_order_one, topSeller.sales as __topSeller_sales, variant.id as __variant_id, variant.ordernumber as __variant_ordernumber, variant.suppliernumber as __variant_suppliernumber, variant.kind as __variant_kind, variant.additionaltext as __variant_additionaltext, variant.sales as __variant_sales, variant.active as __variant_active, variant.instock as __variant_instock, variant.stockmin as __variant_stockmin, variant.weight as __variant_weight, variant.position as __variant_position, variant.width as __variant_width, variant.height as __variant_height, variant.length as __variant_length, variant.ean as __variant_ean, variant.unitID as __variant_unitID, variant.releasedate as __variant_releasedate, variant.shippingfree as __variant_shippingfree, variant.shippingtime as __variant_shippingtime, variant.laststock as __product_laststock, unit.id as __unit_id, unit.description as __unit_description, unit.unit as __unit_unit, variant.packunit as __unit_packunit, variant.purchaseunit as __unit_purchaseunit, variant.referenceunit as __unit_referenceunit, variant.purchasesteps as __unit_purchasesteps, variant.minpurchase as __unit_minpurchase, variant.maxpurchase as __unit_maxpurchase, tax.id as __tax_id, tax.tax as __tax_tax, tax.description as __tax_description, priceGroup.id as __priceGroup_id, priceGroup.description as __priceGroup_description, manufacturer.id as __manufacturer_id, manufacturer.name as __manufacturer_name, manufacturer.img as __manufacturer_img, manufacturer.link as __manufacturer_link, manufacturer.description as __manufacturer_description, manufacturer.meta_title as __manufacturer_meta_title, manufacturer.meta_description as __manufacturer_meta_description, manufacturer.meta_keywords as __manufacturer_meta_keywords, manufacturerAttribute.id as __manufacturerAttribute_id, manufacturerAttribute.supplierID as __manufacturerAttribute_supplierID, manufacturerAttribute.shops_seo_manager_title as __manufacturerAttribute_shops_seo_manager_title, manufacturerAttribute.shops_seo_manager_canonical as __manufacturerAttribute_shops_seo_manager_canonical, manufacturerAttribute.shops_seo_manager_url as __manufacturerAttribute_shops_seo_manager_url, manufacturerAttribute.shops_seo_manager_robots as __manufacturerAttribute_shops_seo_manager_robots, manufacturerAttribute.shops_seo_manager_facebook as __manufacturerAttribute_shops_seo_manager_facebook, manufacturerAttribute.shops_seo_manager_twitter as __manufacturerAttribute_shops_seo_manager_twitter, esd.id as __esd_id, esd.articleID as __esd_articleID, esd.articledetailsID as __esd_articledetailsID, esd.file as __esd_file, esd.serials as __esd_serials, esd.notification as __esd_notification, esd.maxdownloads as __esd_maxdownloads, esd.datum as __esd_datum, esdAttribute.id as __esdAttribute_id, esdAttribute.esdID as __esdAttribute_esdID, (SELECT 1 FROM s_articles_esd variantEsd WHERE variantEsd.articleID = product.id LIMIT 1) as __product_has_esd, (SELECT GROUP_CONCAT(customerGroups.customergroupId SEPARATOR '|') FROM s_articles_avoid_customergroups customerGroups WHERE customerGroups.articleID = product.id) as __product_blocked_customer_groups, (SELECT COUNT(availableVariant.id) FROM s_articles_details availableVariant WHERE (availableVariant.articleID = product.id) AND (availableVariant.active = 1) AND ((availableVariant.laststock * availableVariant.instock) >= (availableVariant.laststock * availableVariant.minpurchase))) as __product_has_available_variants, (SELECT COUNT(DISTINCT ROUND(prices.price, 2)) as priceCount FROM s_articles_prices prices INNER JOIN s_articles_details priceVariant ON priceVariant.id = prices.articledetailsID and priceVariant.active = 1 WHERE (prices.from = 1) AND (prices.pricegroup = ?) AND (prices.articleID = product.id)) as __product_fallback_price_count, manufacturerMedia.id as __manufacturer_img_id, (SELECT COUNT(DISTINCT ROUND(prices.price, 2)) as priceCount FROM s_articles_prices prices INNER JOIN s_articles_details priceVariant ON priceVariant.id = prices.articledetailsID and priceVariant.active = 1 WHERE (prices.from = 1) AND (prices.pricegroup = ?) AND (prices.articleID = product.id)) as __product_custom_price_count FROM s_articles_details variant INNER JOIN s_articles product ON product.id = variant.articleID LEFT JOIN s_core_units unit ON unit.id = variant.unitID LEFT JOIN s_articles_attributes productAttribute ON productAttribute.articledetailsID = variant.id LEFT JOIN s_articles_esd esd ON esd.articledetailsID = variant.id INNER JOIN s_core_tax tax ON tax.id = product.taxID LEFT JOIN s_articles_supplier manufacturer ON manufacturer.id = product.supplierID LEFT JOIN s_core_pricegroups priceGroup ON priceGroup.id = product.pricegroupID LEFT JOIN s_articles_supplier_attributes manufacturerAttribute ON manufacturerAttribute.supplierID = product.supplierID LEFT JOIN s_articles_top_seller_ro topSeller ON topSeller.article_id = product.id LEFT JOIN s_media manufacturerMedia ON manufacturerMedia.path = manufacturer.img LEFT JOIN s_articles_esd_attributes esdAttribute ON esdAttribute.esdID = esd.id WHERE (variant.ordernumber IN (?, ?, ?, ?, ?)) AND (variant.active = 1) AND (product.active = 1)' with params ("EK", "GK", "ZD-FFP3", "ZD-FFP2", "ZD-700000", "ZD-700010", "ZD-700090"):

    Am Ende steht:

    WHERE (variant.ordernumber IN (?, ?, ?, ?, ?)) AND (variant.active = 1) AND (product.active = 1)' with params ("EK", "GK", "ZD-FFP3", "ZD-FFP2", "ZD-700000", "ZD-700010", "ZD-700090"):
    You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '?) AND (prices.articleID = product.id)) as __product_fallback_price_count, manuf' at line 1

    Könnte das die Ursache sein?

  • R4MR4M MemberComments: 2350 Received thanks: 361 edited February 26 Member since: April 2014

    Ich glaube die Ursache gefunden zu haben. Bei einigen Artikel steht trotz aktiven Abverkauf im Lagerbestand eine -1. Jetzt frag ich mich wie das passieren kann. Vermutlich hängt das wieder mit Paypal Express zusammen. Nach dem ich den Lagerbestand von -1 auf 0 gesetzt habe, ist die Fehlermeldung weg.

    Nachtrag:

    Bleibt noch zu klären, warum sich Shopware in einem solchen Fall gleich verabschiedet. Durch diesen Sachverhalt ging die komplette Seite nicht mehr. Sollte im Live-Betrieb nicht passieren, egal ob der Lagerbestand 0 oder -1 ist.

Sign In or Register to comment.