#!/usr/bin/perl -w

use strict;
#use utf8;

my %data;
while(<DATA>) {
    last if (m/__END__/);
    next unless (m/61-8/);
    s/^.*61-8/61-8/;
    #print;
    my ($typnr, $bauteillayout, $schaltbild) = split;
    my $key = sprintf("%2d %2d", $bauteillayout, $schaltbild);
    my $r = $data{$key};
    if ($r) { push @$r, $typnr; }
    else { $data{$key} = [ $typnr ]; }
}
for my $k (sort keys %data) {
    #print "$k ", join(" ", sort @{$data{$k}}), "\n";
    my $a = substr($k, 0, 2);
    my $b = substr($k, 3, 2);
    print "  $a => [ $b, \"", join("\", \"", sort @{$data{$k}}), "\" ]\n";
}

__DATA__
http://www.eao.com/global/de/Catalogues/PDF_Datei_mit_Zeichnungen/EAO_Baureihen_Empfehlung/EAO-Baureihen-61-Daten.pdf
page 33 .. 37, we only interest us in L1 (lötanschluß).

  Anschlüsse Typ-Nr. Bauteilelayout  Schaltbild

Lampenelement L1  61-8006.02 7  3

Diodenelement
1 Diode       L1 61-8101.02  5 20
2 Dioden      L1 61-8102.02  6 21

Schaltelement zu Druck- 2D 250 VAC, 5 A   SP 1S    L1  Au-Ag 61-8212.22 40 28
taste | Schlüssel- und                                 Ag    61-8212.12 40 28
Wahlschalter            -  250 VAC, 5 A   SP 1Ö    L1  Au-Ag 61-8440.22  8 23
2 Stellungen
                                                       Ag    61-8440.12  8 23
mit Lampenanschluss
                                             1Ö+1S L1  Au-Ag 61-8470.22 38 30
                                                       Ag    61-8470.12 38 30
                                             1Ö+2S L1  Au-Ag 61-8490.22 39 32
                                                       Ag    61-8490.12 39 32
                                             1S    L1  Au-Ag 61-8410.22 32 27
                                                       Ag    61-8410.12 32 27
                                             2Ö    L1  Au-Ag 61-8450.22  9 24
                                                       Ag    61-8450.12  9 24
                                             2Ö+1S L1  Au-Ag 61-8480.22 11 31
                                                       Ag    61-8480.12 11 31
                                             2S    L1  Au-Ag 61-8420.22 36 34
                                                       Ag    61-8420.12 36 34
                                             3Ö    L1  Au-Ag 61-8460.22 10 25
                                                       Ag    61-8460.12 10 25
                                             3S    L1  Au-Ag 61-8430.22 37 35
                                                       Ag    61-8430.12 37 35
                                          T  1Ö    L1  Ag    61-8640.17 18 23
                                             1Ö+1S L1  Ag    61-8670.17 17 30
                                             1S    L1  Ag    61-8610.17 15 27
                                             2Ö    L1  Ag    61-8650.17 19 24
                                             2S    L1  Ag    61-8620.17 16 34
                           42 VAC, 100 mA T  1Ö    L1  Au    61-8640.37 18 23
                                             1Ö+1S L1  Au    61-8670.37 17 30
                                             1S    L1  Au    61-8610.37 15 27
                                             2Ö    L1  Au    61-8650.37 19 24
                                             2S    L1  Au    61-8620.37 16 34


Schaltelement zu Schlüssel-   250 VAC, 5 A   SP 1Ö+1S L1 Au-Ag 61-8574.22 14 30
und Wahlschalter 3 Stellungen                            Ag    61-8574.12 14 30
mit Lampenanschluss                             2Ö    L1 Au-Ag 61-8550.22 12 24
                                                         Ag    61-8550.12 12 24
                                                2S    L1 Au-Ag 61-8520.22 13 34
                                                         Ag    61-8520.12 13 34
                                             T  1Ö+1S L1 Ag    61-8770.17 20 30
                                                2Ö    L1 Ag    61-8750.17 22 24
                                                2S    L1 Ag    61-8720.17 21 34
                              42 VAC, 100 mA T  1Ö+1S L1 Au    61-8770.37 20 30
                                                2Ö    L1 Au    61-8750.37 12 24
                                                2S    L1 Au    61-8720.37 13 34

Schaltelement zu Not-Halt Taste, über- 250 VAC, 5 A T 1Ö    L1  Ag 61-8745.17 24 38
                                                      1Ö+1S L1  Ag 61-8775.17 23 37
                                                      2Ö    L1  Ag 61-8755.17 25 36

Schaltelement zu Stopp Taste, 42 VAC, 100 mA T 1Ö    L1 Au 61-8745.37 24 38
überlistsicher                                 1Ö+1S L1 Au 61-8775.37 23 37
                                               2Ö    L1 Au 61-8755.37 25 36

__END__

 the above code gives me:
Bauteilelayout  Schaltbild Typ-Nr...

   5 => [ 20, "61-8101.02" ]
   6 => [ 21, "61-8102.02" ]
   7 => [  3, "61-8006.02" ]
   8 => [ 23, "61-8440.12", "61-8440.22" ]
   9 => [ 24, "61-8450.12", "61-8450.22" ]
  10 => [ 25, "61-8460.12", "61-8460.22" ]
  11 => [ 31, "61-8480.12", "61-8480.22" ]
  12 => [ 24, "61-8550.12", "61-8550.22", "61-8750.37" ]
  13 => [ 34, "61-8520.12", "61-8520.22", "61-8720.37" ]
  14 => [ 30, "61-8574.12", "61-8574.22" ]
  15 => [ 27, "61-8610.17", "61-8610.37" ]
  16 => [ 34, "61-8620.17", "61-8620.37" ]
  17 => [ 30, "61-8670.17", "61-8670.37" ]
  18 => [ 23, "61-8640.17", "61-8640.37" ]
  19 => [ 24, "61-8650.17", "61-8650.37" ]
  20 => [ 30, "61-8770.17", "61-8770.37" ]
  21 => [ 34, "61-8720.17" ]
  22 => [ 24, "61-8750.17" ]
  23 => [ 37, "61-8775.17", "61-8775.37" ]
  24 => [ 38, "61-8745.17", "61-8745.37" ]
  25 => [ 36, "61-8755.17", "61-8755.37" ]
  32 => [ 27, "61-8410.12", "61-8410.22" ]
  36 => [ 34, "61-8420.12", "61-8420.22" ]
  37 => [ 35, "61-8430.12", "61-8430.22" ]
  38 => [ 30, "61-8470.12", "61-8470.22" ]
  39 => [ 32, "61-8490.12", "61-8490.22" ]
  40 => [ 28, "61-8212.12", "61-8212.22" ]
