well it really depends on how you did :
1) you started from 0 took the install/install.php and followed them steps... than they asked the database informations and you gave them and BANG it didnt work.
Reasons :
it can be because you put WRONG informations inside the box so it couldnt connect.
it can be because you set localhost at the server name wich soemtimes is wrong. so try to see if you don't have a correct server name something like server9lcl.secureserver.net wich secure server is used by Godaddy databases

2) you copied and pasted the phpbb2 folder from a host to an other and dint work.
Reasons :
it can be that once you changed hosts it deleted the database :/ wich i guess youll have to start at 0
it can be that you forgot to modify the config.php file wich is inside the phpbb2 folder.*
____
Overall it can be anything since Couldnt connect to Database is very vague... more info maybe ?
if you are trying to start a new forum than use PHPBB3 and not 2 even tho it is at RC7 its still definitly GOOD ! and it definitly ROCKS ! its more over a 2.0 web interface