wp db export

Exports the database to a file or to STDOUT.