Forum

Thread tagged as: Error

Login issues

A client is having problems logging into Perch.

— Did a password reset. — Used new credentials from email — Got a “Sorry, these details are incorrect. Try again” error.

They are hosted on 123 Reg.

Andy Clarke

Andy Clarke 0 points

  • 5 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

Is there any chance you requested the details more than once? If so there could be another email on its way with new details.

It also sounds like you're on an old version of Perch - we don't send new passwords via email any more. Instead you get a secured link to enter a new password.

Hey Drew.

Yes, it is an older version. As far as I know, she’s only requested the password once. I have a sneaking suspicion that this isn’t a Perch issue as much as a hosting one.

Love

Andy

Drew McLellan

Drew McLellan 2638 points
Perch Support

The next thing you can try is turning on debug. This will show the reason for the failure. In your perch/config/config.php file, add:

define('PERCH_DEBUG', true);

Then try to log in again and you should see what's going on at the bottom for the page.

Brilliant.

Here’s the error message I get back:

DIAGNOSTICS:
Activating via CURL
{"result":"SUCCESS","latest_version":"2.8.15","on_sale_version":"2.8.29"}
DELETE FROM perch2_settings WHERE settingID='latest_version' AND userID=0 LIMIT 1
INSERT INTO perch2_settings(settingID,settingValue,userID) VALUES('latest_version','2.8.15',0)
Invalid query: SQLSTATE[42000]: Syntax error or access violation: 1142 INSERT command denied to user 'perch'@'linweb37.atlas.pipex.net' for table 'perch2_settings'
stdClass Object

(

    [result] => SUCCESS

    [latest_version] => 2.8.15

    [on_sale_version] => 2.8.29

)


Activation: success
SELECT u.*, r.* FROM perch2_users u, perch2_user_roles r
WHERE u.roleID=r.roleID AND u.userEnabled='1' AND userUsername='pennyhayler' LIMIT 1
User exists, checking password.
Stronger password hash.
Password failed to match.
SELECT DISTINCT settingID, settingValue FROM perch2_settings WHERE userID=0
Queries: 4
Drew McLellan

Drew McLellan 2638 points
Perch Support

I think this is the crux of the issue:

Invalid query: SQLSTATE[42000]: Syntax error or access violation: 1142 INSERT command denied to user 'perch'@'linweb37.atlas.pipex.net' for table 'perch2_settings'

The database user account doesn't appear to have permission to save to the database.

I suspect that the new password also failed to go into the database when it was created, which is why it's now not recognised.

This is something to ask the host about.