Technote Details :: When I try to preview a page, I get an SQL Error
Issue
When I try to preview a dynamic page creted using MX Kollection, I get an error message: Sql Error: Access denied for user: username@hostname.
Reason
There are two possible causes for this error:
- The password used in the database connection for the user is wrong.
- The user can only connect from specified addresses (e.g. localhost), and not from the address listed in the error message.
- If using ColdFusion, the authorization data entered in the InterAKT Control Panel -> User persistence and Database caching is not correct.
Solution
To fix these problems, you can:
- Check if the password supplied is really correct. To find out, simply connect to the mysql server using the console client, and the username from the error message. When prompted for a password enter the one in the database connection and see if the system allows you to login.
- Add the desired host to the MySQL permissions tables, for the user. To find out how to do this, and more causes for the Access denied error, see the MySQL documentation, available online here.
- On ColdFusion, verify that the same data that is used for RDS login is supplied in the InterAKT Control Panel -> User Interface Persistence and Database Caching