User search index: db upgrade warning on postgres

Bug #796102 reported by François Marier
4
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mahara
Fix Released
Medium
Richard Mansfield

Bug Description

The DB upgrade fails on "if (!index_exists($table, $index)) {" (though it's a warning, not an error)

The upgrade went through and finished but none of these new indexes were created.

Revision history for this message
François Marier (fmarier) wrote :
summary: - User search index: db upgrade error on postgres
+ User search index: db upgrade warning on postgres
Changed in mahara:
importance: High → Low
description: updated
Revision history for this message
Richard Mansfield (richard-mansfield) wrote :

 [11:56] < fmarier> richardm: what you think about bug #796102 ? I wasn't sure how serious it was, but it that index doesn't get created, then I guess that change is useless
 [11:56] < maharabot> Launchpad bug 796102 in mahara "User search index: db upgrade warning on postgres" [Low,Confirmed] https://launchpad.net/bugs/796102 - Assigned to
                      Richard Mansfield (richard-mansfield)
 [11:57] < richardm> ah sorry, i didn't realise the index doesn't get created
 [11:57] < richardm> thought it was just a warning coming from adodb & ddl
 [11:58] < fmarier> i'll double check
 [11:59] -!- iWaa [~iwaa@115.189.110.220] has quit [Quit: iGone]
 [11:59] < fmarier> richardm: yeah none of these indexes got created
 [11:59] < richardm> ok, i'll bump it back up

Changed in mahara:
importance: Low → Medium
Changed in mahara:
importance: Medium → High
importance: High → Medium
Changed in mahara:
status: Confirmed → In Progress
Revision history for this message
Mahara Bot (dev-mahara) wrote :

Reviewed: https://reviews.mahara.org/314
Committed: http://gitorious.org/mahara/mahara/commit/3ac3c40ef38d266e77863d8743bf56285d45cb88
Submitter: Richard Mansfield (<email address hidden>)
Branch: master

commit 3ac3c40ef38d266e77863d8743bf56285d45cb88
Author: Richard Mansfield <email address hidden>
Date: Tue Jun 14 09:58:53 2011 +1200

    Rerun search index upgrade due to failure of index_exists (bug #796102)

    Change-Id: I79c8bf5e458e763e2b8d19f997ca9b708426cc74
    Signed-off-by: Richard Mansfield <email address hidden>

Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/313
Committed: http://gitorious.org/mahara/mahara/commit/166d78921d839588f15cc1c907cb02ef4045f3e6
Submitter: Richard Mansfield (<email address hidden>)
Branch: master

commit 166d78921d839588f15cc1c907cb02ef4045f3e6
Author: Richard Mansfield <email address hidden>
Date: Mon Jun 13 15:35:28 2011 +1200

    Make index_exists more useful when called on indexes with no columns (bug #796102)

    ddl's index_exists() function tries to check whether an index exists on a table
    by comparing the column names in the index passed to it with all the indexes on
    the table.

    Indexes on functions of columns all appear as having no columns, so the behaviour
    is not very useful. If a table has any index on a function, index_exists will
    always return true when passed an index with no columns, whether or not its name
    matches any existing index on the table.

    This change modifies find_index_name() so that it treats indexes without columns
    as a special case, and matches on their names rather than on the list of columns.

    Change-Id: Ic0d664dff77fe5a220a9f9563975df1c87b18e06
    Signed-off-by: Richard Mansfield <email address hidden>

Revision history for this message
Mahara Bot (dev-mahara) wrote :

Reviewed: https://reviews.mahara.org/312
Committed: http://gitorious.org/mahara/mahara/commit/b87d9961020a8d52a2eaf709a9197520b3c6b65b
Submitter: Richard Mansfield (<email address hidden>)
Branch: master

commit b87d9961020a8d52a2eaf709a9197520b3c6b65b
Author: Richard Mansfield <email address hidden>
Date: Mon Jun 13 15:30:35 2011 +1200

    Check for valid columns in adodb postgres64 driver MetaIndexes fn (bug #796102)

    Indexes on functions of columns have a 0 in the indkey column of
    pg_catalog.pg_index, which doesn't refer to a column.

    Don't return any columns for the index, rather than returning an empty
    column name.

    Change-Id: I1464b8a9fda8bd137dcabf1145da289ccf32c500
    Signed-off-by: Richard Mansfield <email address hidden>

Changed in mahara:
status: In Progress → Fix Committed
milestone: none → 1.5.0
Changed in mahara:
milestone: 1.5.0 → none
status: Fix Committed → Fix Released
Revision history for this message
Mahara Bot (dev-mahara) wrote : A patch has been submitted for review

Patch for "master" branch: https://reviews.mahara.org/3949

Revision history for this message
Mahara Bot (dev-mahara) wrote :

Patch for "master" branch: https://reviews.mahara.org/11228

Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/11228
Committed: https://git.mahara.org/mahara/mahara/commit/75100cb7ef9959d40adc9abca93be88385ed9de2
Submitter: Cecilia Vela Gurovic (<email address hidden>)
Branch: master

commit 75100cb7ef9959d40adc9abca93be88385ed9de2
Author: Richard Mansfield <email address hidden>
Date: Mon Jun 13 15:30:35 2011 +1200

Bug 1890213: check for valid columns in driver

Check for valid columns in adodb postgres64 driver MetaIndexes fn (bug #796102)

Indexes on functions of columns have a 0 in the indkey column of
pg_catalog.pg_index, which doesn't refer to a column.

Don't return any columns for the index, rather than returning an empty
column name.

Change-Id: I531e75bacf8c845beadc7d8286eb28ef5281d923
Signed-off-by: Richard Mansfield <email address hidden>

Revision history for this message
Mahara Bot (dev-mahara) wrote : A patch has been submitted for review

Patch for "master" branch: https://reviews.mahara.org/11571

Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/11571
Committed: https://git.mahara.org/mahara/mahara/commit/011c471dcb46ea8a3b9df52d6a1a94eeb70a7428
Submitter: Robert Lyon (<email address hidden>)
Branch: master

commit 011c471dcb46ea8a3b9df52d6a1a94eeb70a7428
Author: Richard Mansfield <email address hidden>
Date: Mon Jun 13 15:30:35 2011 +1200

Check for valid columns in adodb postgres64 driver MetaIndexes fn (bug #796102)

Indexes on functions of columns have a 0 in the indkey column of
pg_catalog.pg_index, which doesn't refer to a column.

Don't return any columns for the index, rather than returning an empty
column name.

Change-Id: I3d89894203b9304d1d72fddf4ba0ca16b05944a8
Signed-off-by: Richard Mansfield <email address hidden>

Revision history for this message
Mahara Bot (dev-mahara) wrote : A patch has been submitted for review

Patch for "master" branch: https://reviews.mahara.org/11744

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.