Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Company,Employees
- '1', '33'
- '2', '36'
- '3', '30'
- '4', '21'
- '5', '36'
- '6', '24'
- .
- .
- my %result;
- while ( my $rec = $slots->fetchrow_hashref ) {
- push @{ $result{ $rec->{"Employees"} } }, $rec->{"CompanyID"};
- }
- @order = map { $result{$_} } sort { $a<=>$b } keys %result;
- Company , Employees
- 1 1
- 1 2
- 1 3
- up till 33 times for company 1.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement