Delicious      Technorati      Blinklist      Furl      Reddit

TimeTrex Time and Attendance

TimeTrex Time and Attendance


* FAQ    * Search
* Login   * Register

All times are UTC - 8 hours [ DST ]




Post new topic Reply to topic  [ 8 posts ] 
Author Message
PostPosted: Thu May 04, 2017 4:41 am 
Offline

Joined: Thu May 04, 2017 4:01 am
Posts: 5
When trying to add, edit or delete a register in HR Qualifications the system gives the following error: "Timetrex is unable to connect to its database, please make sure that the database service on your own local Timetrex server has been started and it's running. If you are unsure, try rebooting your server".
All other transactions can be done without any problem, only this one is giving problems.
We have tried rebooting the server with no success.

ImageTimetrex_screenshot_1 by Benigno Calvo

Community version 10.5.0 running on a windows 7 PC. Running on postgresql 9.5 I believe. It was all installed with the auto installer. And we haven't had any problems adding Qualifications until now.

What can we do to fix this ?. I have tried to check if there were any locks on tables through pg_admin and it doesn't detect any locks. But then my knowledge of pg is very limited so I haven't wanted to touch anything.


Top
 Profile  
 
PostPosted: Thu May 04, 2017 8:01 am 
Offline

Joined: Tue Sep 19, 2006 2:22 pm
Posts: 7255
Please attach a copy of your TimeTrex log file so we can see specifically what error is being triggered. You can find instructions on how to do that here:
http://forums.timetrex.com/viewtopic.php?f=6&t=89


Top
 Profile  
 
PostPosted: Thu May 04, 2017 8:28 am 
Offline

Joined: Thu May 04, 2017 4:01 am
Posts: 5
Hello, find here the error log.

I have done several one to add a new entry, another to modify and another to delete. Both modify and add with description Test de erreur. The one for deletion on a Qualification named Selection.

Thank you for looking into it, Benigno.


Attachments:
File comment: Error Log
timetrex.log [1.15 MiB]
Downloaded 30 times
Top
 Profile  
 
PostPosted: Thu May 04, 2017 8:53 am 
Offline

Joined: Tue Sep 19, 2006 2:22 pm
Posts: 7255
I see the error in your log, but problem appears like it may be coming from your operating system or database, it unfortunately is not saying what the specific problem is though. So we would need see if we can get any other error messages.

Could you attach the c:\timetrex\apache2\logs\error.log, as well as take a look in your Windows event viewer for any errors related to PostgreSQL?


Top
 Profile  
 
PostPosted: Fri May 05, 2017 12:57 am 
Offline

Joined: Thu May 04, 2017 4:01 am
Posts: 5
Hello reproduced the error today with same name Test de Erreur

Attaching both timetrex log and apache log

Thank you for looking into it,
Benigno.


Attachments:
File comment: Apache log
error.log [695.7 KiB]
Downloaded 28 times
File comment: Timetrex log
timetrex.zip [1.01 MiB]
Downloaded 28 times
Top
 Profile  
 
PostPosted: Mon May 08, 2017 4:19 am 
Offline

Joined: Thu May 04, 2017 4:01 am
Posts: 5
Sorry I was not sure how to add the Windows events. Please find them all here, I exported the events to a file.
This are the 2 errors at the event window just in case you cannot open the file sent:

It would look as if the table columns have been changed as visibility_type_id is not in the table any more.
.....................................................................
La description de l’ID d’événement 0 dans la source PostgreSQL est introuvable. Le composant qui a déclenché cet événement n’est pas installé sur l’ordinateur local ou l’installation est endommagée. Vous pouvez installer ou réparer le composant sur l’ordinateur local.

Si l’événement provient d’un autre ordinateur, les informations d’affichage doivent être enregistrées avec l’événement.

Les informations suivantes étaient incluses avec l’événement :

ERROR: current transaction is aborted, commands ignored until end of transaction block
STATEMENT:
SELECT
a.attname,
CASE
WHEN x.sequence_name != ''
THEN 'SERIAL'
ELSE t.typname
END AS typname,
a.attlen, a.atttypmod, a.attnotnull, a.atthasdef, a.attnum
FROM
pg_class c,
pg_attribute a
JOIN pg_type t ON a.atttypid = t.oid
LEFT JOIN (
SELECT
c.relname as sequence_name,
c1.relname as related_table,
a.attname as related_column
FROM pg_class c
JOIN pg_depend d ON d.objid = c.oid
LEFT JOIN pg_class c1 ON d.refobjid = c1.oid
LEFT JOIN pg_attribute a ON (d.refobjid, d.refobjsubid) = (a.attrelid, a.attnum)
WHERE c.relkind = 'S' AND c1.relname = 'qualification'
) x ON x.related_column= a.attname
WHERE
c.relkind in ('r','v')
AND (c.relname='qualification' or c.relname = lower(''))
AND a.attname not like '....%'
AND a.attnum > 0
AND a.attrelid = c.oid
ORDER BY
a.attnum
......................................................................
La description de l’ID d’événement 0 dans la source PostgreSQL est introuvable. Le composant qui a déclenché cet événement n’est pas installé sur l’ordinateur local ou l’installation est endommagée. Vous pouvez installer ou réparer le composant sur l’ordinateur local.

Si l’événement provient d’un autre ordinateur, les informations d’affichage doivent être enregistrées avec l’événement.

Les informations suivantes étaient incluses avec l’événement :

ERROR: column "visibility_type_id" does not exist at character 19
STATEMENT: select id,type_id,visibility_type_id,source_type_id,company_id,group_id,name,name_metaphone,description,updated_date,updated_by from qualification where id = -1
................................................................................

It would look as if the table columns have been changed as visibility_type_id is not in the table any more.


Attachments:
File comment: Windows events
windows events.zip [110.37 KiB]
Downloaded 25 times
Top
 Profile  
 
PostPosted: Mon May 08, 2017 9:43 am 
Offline

Joined: Tue Sep 19, 2006 2:22 pm
Posts: 7255
Yeah, for some reason your database schema appears to be out-of-sync.

You will need to run the following queries manually at the PostgreSQL console:
Code:
CREATE INDEX schedule_replaced_id ON schedule(replaced_id);
ALTER TABLE qualification ADD COLUMN source_type_id integer NOT NULL DEFAULT 10;
ALTER TABLE qualification ADD COLUMN visibility_type_id integer NOT NULL DEFAULT 10;


That should bring it back in sync and everything should start working again.


Top
 Profile  
 
PostPosted: Tue May 09, 2017 12:37 am 
Offline

Joined: Thu May 04, 2017 4:01 am
Posts: 5
Thank you very much Shaunw,

It does indeed fix the problem.

Best regards,
Benigno.

PS: Let me know if you come by Tunisia or Spain, to get you guys a beer.

Thanks again.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 8 posts ] 

All times are UTC - 8 hours [ DST ]


Who is online

Users browsing this forum: Google [Bot] and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron


Time and Attendance




Powered by phpBB® Forum Software © phpBB Group