Most tasks involving the can be accomplished within Quassel itself, and when possible, you should use those options (e.g. deleting chat by right-clicking buffers, Delete Chats). However, some actions, such as deleting Quassel users, deleting backlog older than a certain date, and cleanup require manually modifying the database while the Quassel core is stopped.
The steps to take depend on which database backend you're using. If you don't know, it's most likely SQLite.
See the pages for...
Migrating SQLite to PostgreSQL¶
In many cases, PostgreSQL offers better performance and greater reliability than SQLite.
To migrate, see the setup and migration documentation on the PostgreSQL page.