DISCLAIMER: If you did not know everything in this thread before reading it, you should not be modifying the database directly.
WARNING: If you do modify the database directly, any problems that arise are not ours to fix.
We know this and the dev team modifies the database directly when we need to, but with restrictions and understanding of what we were doing, read the fine print below for details.
Also we never said the database was encrypted so whoever did had no idea what they were talking about and should not have been trying to modify the database anyway.
We tell people not to modify the database without going through the API and leave it at that because everyone stops listening to us when they hear what they want and don't continue listening to the important bits.
There is one basic scenario where it is safe to modify the database: when the server is off. BUT.
The but: only if you are correctly populating all of the fields correctly. If you introduce invalid data, data in an invalid format, or fail to provide needed data when you turn the server back on and it tries to load it, it may very well cause issues and that is the reason we tell you all to not modify the database directly. We do it on a regular basis when we need to test things but the difference is we are usually working with data we can throw away, so if we corrupt something it doesn't matter. Also, if we did corrupt something we needed, we are also the people who know how to fix it (if such a thing is possible).
There is one slightly more complicated where it is also safe to modify the database: when the data you are modifying is not loaded by the server. BUT only player data. If you are modifying the game database it must be off. However you probably should refrain from modifying the player database while it is running (at least until source is released and you are able to check yourself) because there's a chance that something may be loaded when you think it is not.