X-Git-Url: http://koha-dev.rot13.org:8081/gitweb/?a=blobdiff_plain;f=C4%2FMatcher.pm;h=d61964ce2037b0348582e9a96f09ab34871ec64f;hb=bd1d643fadb1f867881ca455bb1709cfae54cd61;hp=9d1df67e585063ece52156298821d8039664f6d5;hpb=97446f86ced2c2d6d4d7a11b97ed81a5a0a25d95;p=koha_gimpoz diff --git a/C4/Matcher.pm b/C4/Matcher.pm index 9d1df67e58..d61964ce20 100644 --- a/C4/Matcher.pm +++ b/C4/Matcher.pm @@ -95,6 +95,22 @@ sub GetMatcherList { return @results; } +=head2 GetMatcherId + + my $matcher_id = C4::Matcher::GetMatcherId($code); + +Returns the matcher_id of a code. + +=cut + +sub GetMatcherId { + my ($code) = @_; + my $dbh = C4::Context->dbh; + + my $matcher_id = $dbh->selectrow_array("SELECT matcher_id FROM marc_matchers WHERE code = ?", undef, $code); + return $matcher_id; +} + =head1 METHODS =head2 new