Add database interaction, but i don't really understand how this works :/