Make WordPress Core

Opened 8 years ago

Last modified 5 years ago

#15004 closed defect (bug)

Missing index on wp_signups — at Initial Version

Reported by: barry Owned by:
Milestone: 3.7 Priority: normal
Severity: normal Version:
Component: Database Keywords: has-patch commit needs-refresh 3.6-early
Focuses: Cc:


wp-includes/ms-functions.php:590: $signup = $wpdb->get_row( $wpdb->prepare("SELECT * FROM $wpdb->signups WHERE user_email = %s", $user_email) ); wp-includes/ms-functions.php:595: $wpdb->query( $wpdb->prepare("DELETE FROM $wpdb->signups WHERE user_email = %s", $user_email) );

But there is no index on user_email in the signups table. Makes these queries perform a full table scan which is slow when you have lots of signups.

Attached patch adds the index but I can't figure out how schema upgrades on MS-specific tables ever get run after the initial activation of MS mode and table creation.

Change History (1)

8 years ago

Note: See TracTickets for help on using tickets.