use strict; use warnings; use feature 'say'; use Bliako::Schema; my $db = Bliako::Schema->connect( 'DBI:mysql:database=Bliako', undef, undef, { RaiseError => 1 }, ); for my $username ('Bliako', '1nickt') { my $user = $db->resultset('User')->search({ name => $username })->first; for my $comment ( $user->comments->all ) { say sprintf( '%s said about the %s "%s": "%s"', $username, $comment->event->type, $comment->event->name, $comment->text ); } }