I've just started to work with the database module, and I have come across a couple of questions. Can you delete an entry from the database module? Can you update or edit an entry that has already been entered? I have some entries in by database that I need to get rid of all together or add some additional information to the entry. Any help would really be appreciated.
Chris Howard
Yes, you should be able to edit and delete entries. If you use the default view templates you should have the
and
icons for editing and deleting (respectively). If you have modified the templates and you don't have these icons you can add them by adding ##edit## and ##delete## to the templates. Hope that helps. 


Is there a way to set the database so that only the person who entered the entry can edit or delete?
That should be the default behavior. Of course teachers and admins have permissions to edit/delete all entries.Is there a way to limit the deleting to only the teacher?
You can try hiding the delete button and displaying it only to the teacher. One way to do that is by displaying the delete buttions only when the page is in edit mode (which only teachers and admins can bring about). This can be done with javascript. And so in this approach the teacher changes to edit mode by clicking the 'Blocks editing on' button which makes the delete buttons appear and then the teacher can delete an entry.
If you are the admin of your system you may be able to achieve that in some other way. I don't know (see http://docs.moodle.org/en/Database_permissions). If not and you would like to pursue the above option a little further and you need more details let me know.
Hi
You've mentioned here "If you have modified the templates and you don't have these icons you can add them by adding ##edit## and ##delete## to the templates" How do you add these to the templates? I would also like to add some new ones i.e. ##print## but not sure how to add them, the only options i get are to add new fields, not 'actions'
You've mentioned here "If you have modified the templates and you don't have these icons you can add them by adding ##edit## and ##delete## to the templates" How do you add these to the templates? I would also like to add some new ones i.e. ##print## but not sure how to add them, the only options i get are to add new fields, not 'actions'