Hi,

A stat that creates a ticketlist is called regularly by cron. There are no errors when calling it on command line with
bin/otrs.GenerateStats.pl -n 10076 -m "my message“ -r recipient@domain.de

When called by cron though I’m getting this error:
 ERROR: OTRS-otrs.GenerateStats.pl-01 Perl: 5.10.0 OS: linux Time: Mon Jan 12 06:00:04 2015

Message: Invalid Date '2099-12-31 23:59:59'!

Traceback (2107):
   Module: Kernel::System::Time::Date2SystemTime (OTRS 3.3.8) Line: 361
   Module: Kernel::System::Time::TimeStamp2SystemTime (OTRS 3.3.8) Line: 215
   Module: Kernel::System::User::GetUserData (OTRS 3.3.8) Line: 326
   Module: Kernel::System::User::UserName (OTRS 3.3.8) Line: 902
   Module: Kernel::System::User::UserList (OTRS 3.3.8) Line: 981
   Module: Kernel::System::Stats::Dynamic::TicketList::GetObjectAttributes (OTRS 3.3.8)
Line: 89
   Module: Kernel::System::Stats::GetStatsObjectAttributes (OTRS 3.3.8) Line: 1373
   Module: Kernel::System::Stats::StatsGet (OTRS 3.3.8) Line: 311
   Module: bin/otrs.GenerateStats.pl (unknown version) Line: 173

ERROR: OTRS-otrs.GenerateStats.pl-01 Perl: 5.10.0 OS: linux Time: Mon Jan 12 06:00:04 2015

Message: Invalid Date '2099-12-31 23:59:59'!

Traceback (2107):
   Module: Kernel::System::Time::TimeStamp2SystemTime (OTRS 3.3.8) Line: 314
   Module: Kernel::System::User::GetUserData (OTRS 3.3.8) Line: 326
   Module: Kernel::System::User::UserName (OTRS 3.3.8) Line: 902
   Module: Kernel::System::User::UserList (OTRS 3.3.8) Line: 981
   Module: Kernel::System::Stats::Dynamic::TicketList::GetObjectAttributes (OTRS 3.3.8)
Line: 89
   Module: Kernel::System::Stats::GetStatsObjectAttributes (OTRS 3.3.8) Line: 1373
   Module: Kernel::System::Stats::StatsGet (OTRS 3.3.8) Line: 311
   Module: bin/otrs.GenerateStats.pl (unknown version) Line: 173

Use of uninitialized value $TimeEnd in subtraction (-) at
/opt/otrs-3.3.8/Kernel/System/User.pm line 329.
Use of uninitialized value $TimeEnd in numeric gt (>) at
/opt/otrs-3.3.8/Kernel/System/User.pm line 332.
creating data at bin/otrs.GenerateStats.pl line 372.
NOTICE: Email sent to
recipient@domain.de

Anyone here with an idea what’s going wrong? I have no clue where to look, though I’m somewhat experienced in Perl and of course OTRS.

Jan Dreyer