changed default value in uploaded table from 0 to -1

git-svn-id: http://yolanda.mister-muffin.de/svn@289 7eef14d0-6ed0-489d-bf55-20463b2d70db
This commit is contained in:
josch 2008-04-09 19:36:34 +00:00
parent 89ae39188d
commit 5c93a028d3
2 changed files with 5 additions and 5 deletions

View file

@ -75,10 +75,10 @@ $dbh->do(qq{create table
coverage varchar(255) not null,
rights varchar(255) not null,
license varchar(255) not null,
filesize int not null,
duration int not null,
width smallint not null,
height smallint not null,
filesize int default -1,
duration int default -1,
width smallint default -1,
height smallint default -1,
fps float not null,
hash char(64) not null,
primary key (id)

View file

@ -43,7 +43,7 @@ while(1)
{
#get fresh video id from db
my $sth = $dbh->prepare(qq{select id, filesize, duration, width, height, fps, hash
from uploaded where duration != 0 and width != 0 and height != 0 limit 1}) or interrupt $dbh->errstr;
from uploaded where filesize != -1 and duration != -1 and width != -1 and height != -1 limit 1}) or interrupt $dbh->errstr;
$sth->execute() or interrupt $dbh->errstr;
my ($id,$filesize, $duration, $width, $height, $fps, $sha) = $sth->fetchrow_array();