1022 |
sub lookup { |
sub lookup { |
1023 |
my ($what, $database, $input, $key, $having) = @_; |
my ($what, $database, $input, $key, $having) = @_; |
1024 |
|
|
1025 |
confess "lookup needs 5 arguments: what, database, input, key, having" unless ($#_ == 4); |
confess "lookup needs 5 arguments: what, database, input, key, having\n" unless ($#_ == 4); |
1026 |
|
|
1027 |
warn "## lookup ($database, $input, $key)", $/ if ($debug > 1); |
warn "## lookup ($database, $input, $key)", $/ if ($debug > 1); |
1028 |
return unless (defined($lookup->{$database}->{$input}->{$key})); |
return unless (defined($lookup->{$database}->{$input}->{$key})); |