Technote Details :: I get an SQL error when an user account expires
Issue
When an user account has expired and the user tries to login, I get an error message:
Error Executing the SQL
Reason
This happens because the field you have configured in the Control Panel > Login Settings > Restrictions to store the expiry interval and the one for the expiration date are of the incorrect type, or the columns do not exist.
Solution
To fix this problem you have to edit the Login settings and make sure that the fields are correctly set up. Also check out the database structure and the type for each field: the interval must be an integer numeric type, while the date must use the date/time format.