Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-24818

Deleting products that belong to eZ Basket and wishlist takes too long

    Details

    • Type: Improvement Improvement
    • Status: Confirmed
    • Priority: High High
    • Resolution: Unresolved
    • Affects Version/s: 4.5.0
    • Fix Version/s: Customer request
    • Component/s: Database related
    • Labels:
      None

      Description

      In environments that have a large database, the operation of deleting a product in the admin interface can take a long time - several hours - due to the fact that the purge method that is called verifies if the deleted object is in the eZ Basket AND in the wishlist.

      The query responsible for this operation is llocated on ezpublish_legacy/kernel/classes/ezcontentobject.php:

      $sql = 'SELECT DISTINCT ezproductcollection_item.productcollection_id
              FROM   ezbasket, ezwishlist, ezproductcollection_item
              WHERE  ( ezproductcollection_item.productcollection_id=ezbasket.productcollection_id OR
                       ezproductcollection_item.productcollection_id=ezwishlist.productcollection_id ) AND
                      ezproductcollection_item.contentobject_id=' . $delID;
      

      Please optimize this query.

        Activity

        There are no comments yet on this issue.

          People

          • Assignee:
            Unassigned
            Reporter:
            Nuno Oliveira (Inactive)
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated: