Author Topic: Unknown column 'password' in field list'  (Read 13129 times)

Offline zosoi

  • Newbie
  • *
  • Posts: 7
Unknown column 'password' in field list'
« on: August 18, 2012, 11:20:50 AM »
Hello all,

I have this (part of) message in error log by trying to implement the password plugin.

[Native message: Unknown column 'password' in 'field list']  in /home/xxxx/www/webmail/rc/program/include/rcube_mdb2.php

I've put below lines in plugins/password/config.inc.php
Code: [Select]
$rcmail_config['password_driver'] = 'sql';
$rcmail_config['password_query'] = 'UPDATE users SET password=%c WHERE username=%u LIMIT 1';

Obviously, all attempt of password change gives error message.

I begin to use roundcube since few days, so feel free to ask if I should give you other details.

Many thanks in advance for you help.

Offline SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,879
    • SKaero - Custom Roundcube development
Re: Unknown column 'password' in field list'
« Reply #1 on: August 18, 2012, 09:46:25 PM »
It looks like your trying to change the password in the RoundCube database, make sure sure you set password_db_dsn to connect to the database where the mail accounts are setup.

Offline zosoi

  • Newbie
  • *
  • Posts: 7
Re: Unknown column 'password' in field list'
« Reply #2 on: August 19, 2012, 10:36:21 AM »
Thanks SKaero for your reply. I think my setting in password_db_dsn is good; but it seems that the field 'password' doesn't exist in the database.

Here is the full error message:
Quote
[19-Aug-2012 16:49:25] MDB2 Error: no such field (-19): _doQuery: [Error message: Could not execute statement]
[Last executed query: UPDATE users SET password='$1$xPT6JhAZ$QzvUHeTSw2XRte1E0dgj00' WHERE username='user@xxx.com' LIMIT 1]
[Native code: 1054]
[Native message: Unknown column 'password' in 'field list']

I tried to set other password in the password_db_dsn and I have this error message :

Quote
[19-Aug-2012 16:40:28] MDB2 Error: connect failed (-24): _doConnect: [Error message: unable to establish a connection]
[Native code: 0]

Offline SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,879
    • SKaero - Custom Roundcube development
Re: Unknown column 'password' in field list'
« Reply #3 on: August 19, 2012, 07:43:28 PM »
password_db_dsn should be the connection string for the database where the user information is stored. It should be formatted like so:
Quote
$rcmail_config['db_dsnw'] = 'mysql://DBuser:DBpassword@DBhost/DBdatabase';

Offline zosoi

  • Newbie
  • *
  • Posts: 7
Re: Unknown column 'password' in field list'
« Reply #4 on: August 20, 2012, 04:33:26 AM »
I have only 2 kinds of password :
 - First for log in to webmin : usernameA + passwordA (host : kimsufi)
 - The second for log in to phpmyadmin mysql database : usernameB + passwordB

Here what I put in this line

Code: [Select]
$rcmail_config['password_db_dsn'] = 'mysql://usernameB:passwordB@localhost/myDBname'

I use Roundcube Webmail 0.8.0, and if I put the same password in old and new one - I have not the error message.

Please, tell me where I'm wrong in this line.
« Last Edit: August 20, 2012, 04:39:17 AM by zosoi »

Offline SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,879
    • SKaero - Custom Roundcube development
Re: Unknown column 'password' in field list'
« Reply #5 on: August 20, 2012, 04:43:02 AM »
I don't know how webmin stores email accounts so I can't tell you the database name or even where to look for it. Are you sure webmin even stores email account in a database?

Offline zosoi

  • Newbie
  • *
  • Posts: 7
Re: Unknown column 'password' in field list'
« Reply #6 on: August 20, 2012, 09:45:13 AM »
I don't know how webmin stores email accounts so I can't tell you the database name or even where to look for it. Are you sure webmin even stores email account in a database?

yes - I am. In the webmin, I have just to select the OVHM option to have access to the mail database. Our database is in MySQL 5.0.44 version.

Have a look at the users' fields, there is no password field.


Offline JohnDoh

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2,850
Re: Unknown column 'password' in field list'
« Reply #7 on: August 20, 2012, 10:12:51 AM »
thats the roundcube database not your imap account database. the password plugin needs to be configured to access what ever database stores your imap account information. there are no passwords sorted in roundcube.
Roundcube Plugins: Contextmenu, SpamAssassin Prefs, and moreā€¦

Offline zosoi

  • Newbie
  • *
  • Posts: 7
Re: Unknown column 'password' in field list'
« Reply #8 on: August 20, 2012, 02:50:59 PM »
thats the roundcube database not your imap account database. the password plugin needs to be configured to access what ever database stores your imap account information. there are no passwords sorted in roundcube.

Many thanks JohnDoh for your reply but sorry, I couldn't find where the imap account database is stored. I found no other database.

Offline SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,879
    • SKaero - Custom Roundcube development
Re: Unknown column 'password' in field list'
« Reply #9 on: August 20, 2012, 03:24:02 PM »
I'm going to guess that you need to use a different driver, I don't think webmin stores the details in a database.

Offline zosoi

  • Newbie
  • *
  • Posts: 7
Re: Unknown column 'password' in field list'
« Reply #10 on: August 21, 2012, 02:59:54 AM »
I'm going to guess that you need to use a different driver, I don't think webmin stores the details in a database.

Hello guys !

Many many thanks for your help ! According to your suggestions, I've tried the qmailadmin plugin and it works very well for me.

You're great guys !
« Last Edit: August 21, 2012, 07:38:08 AM by zosoi »