Uploaded image for project: 'Sakai'
  1. Sakai
  2. SAK-28787

Remove "unique" from SST_PREFERENCES.SITE_ID db field

    XMLWordPrintable

    Details

    • Type: Task
    • Status: CLOSED
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.7.2
    • Fix Version/s: 2.8.3
    • Component/s: Sitestats
    • Labels:
      None
    • Conversion Script Required:
      Yes

      Description

      Remove "unique" from SST_PREFERENCES.SITE_ID db field.

      From Anthony White email:
      arwhyte-macbookpro-2010:liquibase-1.9.5 arwhyte$ java -jar ./liquibase-1.9.5.jar --driver=com.mysql.jdbc.Driver --url=jdbc:mysql://127.0.0.1:3306/sakai262to270convert --username=sakaiuser --password=sushi diff --baseUrl=jdbc:mysql://127.0.0.1:3306/sakai270autogen --baseUsername=sakaiuser --basePassword=sushi
      Diff Results:
      Base Database: sakaiuser jdbc:mysql://127.0.0.1:3306/sakai270autogen
      Target Database: sakaiuser jdbc:mysql://127.0.0.1:3306/sakai262to270convert

      Missing Indexes (auto-generated 2.7.x db):
      MFR_EMAIL_CONTEXT_ID_I unique on mfr_email_notification_t(CONTEXT_ID)
      MFR_EMAIL_USER_ID_I unique on mfr_email_notification_t(USER_ID)
      PROFILE_FRIENDS_FRIEND_UUID_I unique on profile_friends_t(FRIEND_UUID)
      PROFILE_FRIENDS_USER_UUID_I unique on profile_friends_t(USER_UUID)
      PROFILE_IMAGES_IS_CURRENT_I unique on profile_images_t(IS_CURRENT)
      PROFILE_IMAGES_USER_UUID_I unique on profile_images_t(USER_UUID)
      SAKAI_PERSON_META_PROPERTY_I unique on sakai_person_meta_t(PROPERTY)
      SAKAI_PERSON_META_USER_UUID_I unique on sakai_person_meta_t(USER_UUID)
      SST_EVENTS_DATE_IX unique on sst_events(EVENT_DATE)
      SST_EVENTS_EVENT_ID_IX unique on sst_events(EVENT_ID)
      SST_EVENTS_SITEEVENTUSER_ID_IX unique on sst_events(SITE_ID, EVENT_ID, USER_ID)
      SST_EVENTS_SITE_ID_IX unique on sst_events(SITE_ID)
      SST_EVENTS_USER_ID_IX unique on sst_events(USER_ID)
      SST_PREFERENCES_SITE_ID_IX unique on sst_preferences(SITE_ID)
      SST_REPORTS_SITE_ID_IX unique on sst_reports(SITE_ID)
      SST_RESOURCES_DATE_IX unique on sst_resources(RESOURCE_DATE)
      SST_RESOURCES_RES_ACT_IDX unique on sst_resources(RESOURCE_ACTION)
      SST_RESOURCES_SITE_ID_IX unique on sst_resources(SITE_ID)
      SST_RESOURCES_USER_ID_IX unique on sst_resources(USER_ID)
      SST_SITEACTIVITY_DATE_IX unique on sst_siteactivity(ACTIVITY_DATE)
      SST_SITEACTIVITY_EVENT_ID_IX unique on sst_siteactivity(EVENT_ID)
      SST_SITEACTIVITY_SITE_ID_IX unique on sst_siteactivity(SITE_ID)
      SST_SITEVISITS_DATE_IX unique on sst_sitevisits(VISITS_DATE)
      SST_SITEVISITS_SITE_ID_IX unique on sst_sitevisits(SITE_ID)

      Unexpected Indexes:
      SITE_ID on sst_preferences(SITE_ID)

      Nuno-I believe the above unexpected index involves the CREATE TABLE statement that defines SITE_ID as NOT NULL unique followed by an index statement on the same field. I assume "unique" needs to be removed from 2.1.x and a new release of sitestats 2.1.x generated. My modified conversion script (not checked in yet) removed unique from the statement in the conversion scripts and the 2.6.2>2.7.0 upgraded db includes the key. The auto-generated 2.7.x db does not.

        Gliffy Diagrams

          Zeplin

            Attachments

              Issue Links

                Activity

                  People

                  Assignee:
                  nfernandes Nuno Fernandes (Inactive)
                  Reporter:
                  nfernandes Nuno Fernandes (Inactive)
                  Votes:
                  0 Vote for this issue
                  Watchers:
                  0 Start watching this issue

                    Dates

                    Created:
                    Updated:
                    Resolved:

                      Git Integration