Changed print block to loop

The code is of course valid as it is, but I believe a for statement is what makes sense here, assuming you want to print all the entries in the database.