Details

    • Branch Version/s:
      6.1.x
    • Backported to Branch:
      Committed
    • Fix Priority:
      4
    • Similar Issues:
      Show 5 results 

      Description

      Steps of reproduction:
      1. Go to Control Panel -> Categories
      2. Create a new Vocabulary.
      3. Create two categories into this Vocabulary (e.g. Cat1. Cat2)
      4. Create a subcategory for both of them. (e.g. Cat1 -> Cat11, Cat2 -> Cat21)
      5. Go to your site, and create an Asset Publisher.
      6. Click on Configuration.
      7. Under the Filter Select "Contains" "All" of the following "Categories"
      8. Click on Select button, and choose two categories, which have subcategories (e.g. Cat1, Cat2) or two subcategories (e.g. Cat11, Cat21).
      9. Click on Save
      10. The result is an error message in the log. I attach this.

        Issue Links

          Activity

          Hide
          Laszlo Csontos added a comment -

          Problematic SQL:

           
          SELECT COUNT(DISTINCT AssetEntry.entryId) AS COUNT_VALUE FROM AssetEntry
          WHERE  (visible = ?)
          AND (  EXISTS ( SELECT 1 FROM AssetEntries_AssetCategories WHERE (AssetEntries_AssetCategories.entryId = AssetEntry.entryId) AND (AssetEntries_AssetCategories.categoryId = 39185) )
          AND   EXISTS ( SELECT 1 FROM AssetEntries_AssetCategories WHERE (AssetEntries_AssetCategories.entryId = AssetEntry.entryId) AND (AssetEntries_AssetCategories.categoryId IN (37545,38277,38285,38293,38309,38428,38436,38444,38452,38467,38475,38483,38491,38499,38507,38515,38523,38531,38539,38547,38555,38571,38579,38596,38604,38619,38634,38642,38651,38659,38668,38677,38685,38693,38701,38709,38717,39071,39088,39121,39129)) )
          ***   EXISTS ( SELECT 1 FROM AssetEntries_AssetCategories WHERE (AssetEntries_AssetCategories.entryId = AssetEntry.entryId) AND (AssetEntries_AssetCategories.categoryId IN (38491,38499,38507,38515,38523,38531,38539,38547,38555,39088,39129)) )   )
          AND ( AssetEntry.classTypeId = 39231)
          AND (AssetEntry.publishDate IS NULL OR AssetEntry.publishDate < ?)
          AND (AssetEntry.expirationDate IS NULL OR AssetEntry.expirationDate > ?)
          AND (AssetEntry.groupId = ? )
          AND (AssetEntry.classNameId = ?) 
          

          Note: there is a missing "AND" in the place of the three stars.

          Show
          Laszlo Csontos added a comment - Problematic SQL: SELECT COUNT(DISTINCT AssetEntry.entryId) AS COUNT_VALUE FROM AssetEntry WHERE (visible = ?) AND ( EXISTS ( SELECT 1 FROM AssetEntries_AssetCategories WHERE (AssetEntries_AssetCategories.entryId = AssetEntry.entryId) AND (AssetEntries_AssetCategories.categoryId = 39185) ) AND EXISTS ( SELECT 1 FROM AssetEntries_AssetCategories WHERE (AssetEntries_AssetCategories.entryId = AssetEntry.entryId) AND (AssetEntries_AssetCategories.categoryId IN (37545,38277,38285,38293,38309,38428,38436,38444,38452,38467,38475,38483,38491,38499,38507,38515,38523,38531,38539,38547,38555,38571,38579,38596,38604,38619,38634,38642,38651,38659,38668,38677,38685,38693,38701,38709,38717,39071,39088,39121,39129)) ) *** EXISTS ( SELECT 1 FROM AssetEntries_AssetCategories WHERE (AssetEntries_AssetCategories.entryId = AssetEntry.entryId) AND (AssetEntries_AssetCategories.categoryId IN (38491,38499,38507,38515,38523,38531,38539,38547,38555,39088,39129)) ) ) AND ( AssetEntry.classTypeId = 39231) AND (AssetEntry.publishDate IS NULL OR AssetEntry.publishDate < ?) AND (AssetEntry.expirationDate IS NULL OR AssetEntry.expirationDate > ?) AND (AssetEntry.groupId = ? ) AND (AssetEntry.classNameId = ?) Note: there is a missing "AND" in the place of the three stars.
          Hide
          Laszlo Csontos added a comment -

          Hi,

          Please review my changes:
          https://github.com/zberentey/liferay-portal/pull/130

          Thx,
          Laszlo

          Show
          Laszlo Csontos added a comment - Hi, Please review my changes: https://github.com/zberentey/liferay-portal/pull/130 Thx, Laszlo
          Hide
          Michael Saechang added a comment -

          Committed on:
          Portal 6.2.x GIT ID: b155d74834bf3ada0281a6dfa6ad9fdc7b177096.

          Show
          Michael Saechang added a comment - Committed on: Portal 6.2.x GIT ID: b155d74834bf3ada0281a6dfa6ad9fdc7b177096.
          Hide
          Luyang Tan (Inactive) added a comment - - edited

          PASSED Manual Testing following the steps in the description.

          Reproduced on:
          Tomcat 7.0 + MySQL 5. Portal 6.1.x EE GIT ID: 371b8b346132540f4717432949289fcc2a50696f.

          I will see the console error as the attachment shown.

          Fixed on:
          Tomcat 7.0 + MySQL 5. Portal 6.1.x EE GIT ID: c2ac6f0732dc2e5dd0b551c36b9637542a29e299.
          Tomcat 7.0 + MySQL 5. Portal 6.2.x GIT ID: b155d74834bf3ada0281a6dfa6ad9fdc7b177096.

          There's no error in the console.

          Show
          Luyang Tan (Inactive) added a comment - - edited PASSED Manual Testing following the steps in the description. Reproduced on: Tomcat 7.0 + MySQL 5. Portal 6.1.x EE GIT ID: 371b8b346132540f4717432949289fcc2a50696f. I will see the console error as the attachment shown. Fixed on: Tomcat 7.0 + MySQL 5. Portal 6.1.x EE GIT ID: c2ac6f0732dc2e5dd0b551c36b9637542a29e299. Tomcat 7.0 + MySQL 5. Portal 6.2.x GIT ID: b155d74834bf3ada0281a6dfa6ad9fdc7b177096. There's no error in the console.

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Days since last comment:
                3 years, 2 weeks, 5 days ago

                Development

                  Structure Helper Panel