That explains it, I have seen this exact thing cause the same exact problem with numerous websites.
Your website rankings depend on relevancy, authority, and trust. If your website was responding slowly and then suffered a failure, the Googlebot would recognize your site as untrustworthy for SERPs. Your database problem may have been causing problems that got gradually worse until it failed completely. That is often how these issues progress.
Trust is earned over time, the fact that you have fixed your database issues will not instantly restore trust. You must earn it by demonstrating that your website can be relied upon to serve pages reliable over an extended period of time. Don’t follow the advice of those folks that are ignoring this significant fact.
If you start doing crazy things, based on a sense of paranoia, you are likely to do more damage than good. In my opinion, from what I have seen posted so far on this thread, no one is addressing the most obvious and most likely cause of your rankings drop. The solution is to make sure your server performance remains fast and reliable and that your content does not change significantly, else you will continue to suffer from a poor trust ranking.