编写代码过程中所遇到的印象深刻的错误
when i did my web final project,i encountered a big error.this project need to connect database,
but my computer have some problems and can’t install mysql database.finally i use the wamppserver
to instand of mysql database.wamppserver is a integrated installation environment of Windows
Apache Mysql Php.
When i went to connect the database ,i first looked up the port of wamppserver.i shows 80 ports.so
i thought i need use port 80 to connection database.but when i use url "jdbc:mysql://localhost:80/test?autoReconnect=true&useUnicode=true&characterEncoding=utf-8" to connection ,it always shows
“om.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: Could not create connection to
database server. Attempted reconnect 3 times. Giving up.” error,and can’t connect databse.
I used 3 days to find the problem,and finally find port 80 is appache DSHM,the mysql DSHM IS 3306,
so i changed the port ,and saved this problems.