X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~yarrgweb/git?p=ypp-sc-tools.db-test.git;a=blobdiff_plain;f=yarrg%2Fdb-idempotent-populate;h=eb1a30b43a581047e330b4f226670083366e3fb0;hp=bb0448ce478389c1c030220514c1cdabe648f588;hb=HEAD;hpb=663db396d271b241a8ec76bd44fbda9ec432e10f diff --git a/yarrg/db-idempotent-populate b/yarrg/db-idempotent-populate index bb0448c..2b63f2b 100755 --- a/yarrg/db-idempotent-populate +++ b/yarrg/db-idempotent-populate @@ -29,6 +29,8 @@ # are used without permission. This program is not endorsed or # sponsored by Three Rings. +BEGIN { unshift @INC, qw(.) } + use strict (qw(vars)); use DBI; @@ -229,6 +231,7 @@ table_maycompact('commods', 'commodid', commodclassid INTEGER NOT NULL ordval INTEGER NOT NULL posinclass INTEGER NOT NULL + flags TEXT NOT NULL END table_maycompact('islands', 'islandid', @@ -343,6 +346,7 @@ END commodclassid ordval posinclass + flags ); my $insert= $dbh->prepare(" INSERT OR IGNORE INTO $table{commods} @@ -370,7 +374,8 @@ END $c->{Volume}, $clid, commodsortkey($commod), - $posincl{$commod} + $posincl{$commod}, + $c->{Flags} ); $insert->execute($commod, @valuevalues); $update->execute(@valuevalues, $commod);