This is a quick tip.
If you need to connect to the MySQL databases via command line on a plesk server, simply issue this command.
mysql -uadmin -p`cat /etc/psa/.psa.shadow`
Note: Those are backticks around the cat command, not single quotes. The backtick is the same key as the ~ key on your keyboard.