Uploaded image for project: 'PUBLIC - Liferay Sync'
  1. PUBLIC - Liferay Sync
  2. SYNC-1666

Upgrade of com.liferay.sync.service doesn't work in postgresql

    Details

    • Type: Regression Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: Connector-4.0.3
    • Fix Version/s: Connector-4.0.4
    • Component/s: Upgrade
    • Labels:
      None
    • Fix Priority:
      4
    • Affects Portal Version/s:
      Master
    • Databases:
      PostgreSQL 9.4

      Description

      Upgrade of com.liferay.sync.service doesn't work in postgresql.

      The issue is caused by following SQL added to upgrade in SYNC-1612

      select Lock_.expirationDate, Lock_.userId, Lock_.userName, DLFileVersion.fileEntryId
      from DLFileVersion, Lock_ where DLFileVersion.version = 'PWC' and DLFileVersion.fileEntryId = Lock_.key_
      

      This SQL fails in Postgresql due to column type mismatch but works in MySQL and Oracle.

      Steps to reproduce

      1. Install Liferay 6.2 using postgresql
      2. Upgrade from 6.2 to 7.0.2 GA3. Upgrade will fail in com.liferay.sync.service module
      g! upgrade:execute com.liferay.sync.service
      INFO - Upgrading com.liferay.sync.internal.upgrade.v1_0_2.UpgradeSyncDLObject
      INFO - Starting com.liferay.sync.internal.upgrade.v1_0_2.UpgradeSyncDLObject#doUpgrade
      INFO - Completed com.liferay.sync.internal.upgrade.v1_0_2.UpgradeSyncDLObject#doUpgrade in 29 ms
      INFO - Completed upgrade process com.liferay.sync.internal.upgrade.v1_0_2.UpgradeSyncDLObject in 31ms
      gogo: RuntimeException: com.liferay.portal.kernel.upgrade.UpgradeException: com.liferay.portal.kernel.exception.PortalException: org.postgresql.util.PSQLException: ERROR: operator does not exist: bigint = character varying
        Hint: No operator matches the given name and argument type(s). You might need to add explicit type casts.
        Position: 178
      

        Attachments

          Issue Links

            Activity

              People

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

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Days since last comment:
                  3 years, 14 weeks ago

                  Packages

                  Version Package
                  Connector-4.0.4