MYSql ADODB_Exception'

Ask your questions regarding TimeTrex installation here.
Locked
NavaneethKapil
Posts: 3
Joined: Fri Nov 26, 2010 10:45 pm

MYSql ADODB_Exception'

Post by NavaneethKapil »

i am trying to install Timtrex with Mysql version 5.0.16 on windows Xp



PHP Fatal error: Uncaught exception 'ADODB_Exception' with message 'mysqlt error: [1060: Duplicate column name 'time_zone'] in adodb_throw(alter table pay_period_schedule add column time_zone varchar(250), )\n' in D:\\Program Files\\TimeTrex\\timetrex\\classes\\adodb\\adodb-exceptions.inc.php:78\nStack trace:\n#0 D:\\Program Files\\TimeTrex\\timetrex\\classes\\adodb\\adodb.inc.php(221): adodb_throw('mysqlt', 'adodb_throw', 1060, 'Duplicate colum...', 'alter table pay...', false, Object(ADODB_mysqlt))\n#1 D:\\Program Files\\TimeTrex\\timetrex\\classes\\adodb\\adodb.inc.php(886): ADODB_TransMonitor('mysqlt', 'EXECUTE', 1060, 'Duplicate colum...', 'alter table pay...', false, Object(ADODB_mysqlt))\n#2 D:\\Program Files\\TimeTrex\\timetrex\\classes\\adodb\\adodb.inc.php(861): ADOConnection->_Execute('alter table pay...', false)\n#3 D:\\Program Files\\TimeTrex\\timetrex\\classes\\modules\\install\\InstallSchema_Base.class.php(112): ADOConnection->Execute('alter table pay...')\n#4 D:\\Program Files\\TimeTrex\\timetrex\\classes\\modules\\install\\InstallSchema_Base.class.php(1 in D:\\Program Files\\TimeTrex\\timetrex\\classes\\adodb\\adodb-exceptions.inc.php on line 78, referer: http://localhost:8005/interface/install ... installer=


Default Storage Engine is InnoDB
but it not shown on Data Base configuration page

; Database connection settings. These can be set from the installer.
;
[database]
type = mysqlt

host = localhost:3306
database_name = timetrex
user = timetrex
password = timetrex

thanks
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Re: MYSql ADODB_Exception'

Post by shaunw »

Try deleting the TimeTrex database then try to install again, it appears that there is a conflict with existing data in it.
NavaneethKapil
Posts: 3
Joined: Fri Nov 26, 2010 10:45 pm

Re: MYSql ADODB_Exception'

Post by NavaneethKapil »

same thing happens after deleting TimeTrex database.
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Re: MYSql ADODB_Exception'

Post by shaunw »

Try using the database type: "mysqli" instead of "mysqlt". It requires the PHP MySQLi extension as well.
NavaneethKapil
Posts: 3
Joined: Fri Nov 26, 2010 10:45 pm

Re: MYSql ADODB_Exception'

Post by NavaneethKapil »

again same error, exactly whats the problem ?
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Re: MYSql ADODB_Exception'

Post by shaunw »

Did you delete the TimeTrex database again before you tried the MySQLi driver?

The issue is that MySQL is reporting a duplicate column in a specific table, which shouldn't ever happen unless the table was created and an error occurred, then you tried to install over top of the same database again. This can easily happen with MySQL since it doesn't offer DDL transactions and is one reason why we don't recommend using MySQL as a database.

Anytime an error such as this happens you must either delete the database completely or restore from a backup. Again this is something that MySQL lacks and has nothing to do with TimeTrex. We recommend using a PostgreSQL database instead as it can properly recover from such issues without any problems whatsoever.
Cynjut
Posts: 13
Joined: Tue Jan 04, 2011 5:29 pm

Re: MYSql ADODB_Exception'

Post by Cynjut »

I was looking at that. I'm trying to integrate TimeTrex with the rest of my library management software, which all used MySQL. The error appears to be an erroneous "Limit 1" getting added to the queries. One of the queries was short enough to show the dual "Limit 1" entries on the end of the query string. I installed Postgres and switched to that, and the error is either not there (as in, messed up for MySQL only) or is ignored (as in, PGSQL is more tolerant of errors in the SQL).

Either way, the PGSQL side seems to work, so I have Postgres installed for this product, and this product alone.
Locked