]> Sergey Matveev's repositories - public-inbox.git/blobdiff - lib/PublicInbox/Msgmap.pm
extmsg: use Xapian only for partial matches
[public-inbox.git] / lib / PublicInbox / Msgmap.pm
index 6e758c1aa789d19951829ef5e7f4262751c518e7..192e311aec2b1d459407e0853cfcecb26c2f0448 100644 (file)
@@ -36,7 +36,6 @@ sub dbh_new {
                ReadOnly => !$writable,
                sqlite_use_immediate_transaction => 1,
        });
-       $dbh->do('PRAGMA case_sensitive_like = ON');
        $dbh;
 }
 
@@ -151,23 +150,6 @@ sub minmax {
        ($min, $sth->fetchrow_array);
 }
 
-sub mid_prefixes {
-       my ($self, $pfx, $limit) = @_;
-
-       die "No prefix given" unless (defined $pfx && $pfx ne '');
-       $pfx =~ s/([%_])/\\$1/g;
-       $pfx .= '%';
-
-       $limit ||= 100;
-       $limit += 0; # force to integer
-       $limit ||= 100;
-
-       $self->{dbh}->selectcol_arrayref('SELECT mid FROM msgmap ' .
-                                        'WHERE mid LIKE ? ESCAPE ? ' .
-                                        "ORDER BY num DESC LIMIT $limit",
-                                        undef, $pfx, '\\');
-}
-
 sub mid_delete {
        my ($self, $mid) = @_;
        my $dbh = $self->{dbh};