case 'gen_cohort': $result = $pdo->prepare(<<<EOF SELECT `cohort`, \t{$format} FROM `moles` WHERE `alley` <> 'Social' \tAND `cohort` <> '' \tAND `cohort` >= {$year} \tAND `position` <> 'RA' {$order} EOF ); $result->execute(); $rows = $result->fetchAll(PDO::FETCH_COLUMN | PDO::FETCH_GROUP); foreach ($rows as $class => $moles) { $list = strtolower(Mole::yearToCohort($class)); if ($list != 'frosh') { $list .= 's'; } else { $moles[] = <<<EOF mole-permafrosh <*****@*****.**> EOF; } $moles[] = $president; $moles[] = $secretary; hovselist_write('mole-' . $list, $moles); $lists[] = 'mole-' . $list; } break; case 'gen_gender':