Hello, yesterday I noticed, that my filter purgewhenfull doesn't works.
I have a problem executing zmfilter.pll that returns me the next information
DBD::mysql::db prepare_cached warning: at ./zmfilter.pl line 512.
Can't prepare 'select E.Id,E.MonitorId,M.Name as MonitorName,M.DefaultRate,M.Def aultScale,E.Name,E.Cause,E.Notes,E.StartTime,unix_timestamp(E.StartTime) as Time ,E.Length,E.Frames,E.AlarmFrames,E.TotScore,E.AvgScore,E.MaxScore,E.Archived,E.V ideoed,E.Uploaded,E.Emailed,E.Messaged,E.Executed from Events as E inner join Mo nitors as M on M.Id = E.MonitorId where not isnull(E.EndTime) and ( 73 >= 67% ) order by E.StartTime asc limit 0, 1000': at /usr/lib/perl5/site_perl/5.8.7/Zone Minder/Debug.pm line 321
ZoneMinder::Debug::Fatal('Can\'t prepare \'select E.Id,E.MonitorId,M.Nam e as MonitorNam...') called at ./zmfilter.pl line 512
main::checkFilter('HASH(0x8727368)') called at ./zmfilter.pl line 181
Could you say me, where is the problem here, i think that could be something about perl modules.
REGARDS
problem executing zmfilter.pl
- zoneminder
- Site Admin
- Posts: 5215
- Joined: Wed Jul 09, 2003 2:07 pm
- Location: Bristol, UK
- Contact:
- zoneminder
- Site Admin
- Posts: 5215
- Joined: Wed Jul 09, 2003 2:07 pm
- Location: Bristol, UK
- Contact:
I would try a couple of things. One try executing the sql statement that is output in the error directly in the mysql command line client to check that the syntax is ok. Then just create a simple perl script with a few simple sql statements in to check that the perl database modules work properly.
Something like
though this is just from memory and not tested
Something like
Code: Select all
#!/usr/bin/perl -w
use ZoneMinder;
my $dbh = DBI->connect( "DBI:mysql:database=".ZM_DB_NAME.";host=".ZM_DB_HOST, ZM_DB_USER, ZM_DB_PASS );
my $sql = "select * from Monitors";
my $sth = $dbh->prepare_cached( $sql ) or die( "Can't prepare '$sql': ".$dbh->errstr() );
my $res = $sth->execute() or die( "Can't execute: ".$sth->errstr() );
while( my $monitor = $sth->fetchrow_hashref() )
{
print( $monitor->{Name}."\n" );
}
Phil
the problem was fixed
Hi again, the problem, was fixed updating perl modules, there was a conflict with the libraries.
ZM is running well
THANKS a Lot
ZM is running well
THANKS a Lot