in reply to validate mongoDB result through perl

Look at the last_error() method. Keep in mind that it returns a hash reference.

my $err = $database->last_error();

You posted essentially the same question quite recently: how to capture status codes of mongodb in perl. Did you try the suggestions given to you previously?

- Luke