diff options
author | emkael <emkael@tlen.pl> | 2014-09-28 17:59:57 +0200 |
---|---|---|
committer | emkael <emkael@tlen.pl> | 2014-09-28 17:59:57 +0200 |
commit | c49534808361d004fb53f1241e97d306d86e3fc0 (patch) | |
tree | daa9c6cdc0605c4587516ae46fc76dbbaf7d77b3 | |
parent | 895f8266ce9aa8c214001b75379adcdfe19dcaa0 (diff) |
* korekta meczów tylko, jeśli są w nich zapisy
-rw-r--r-- | patton-imp.sql | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/patton-imp.sql b/patton-imp.sql index 22f766f..c7163f4 100644 --- a/patton-imp.sql +++ b/patton-imp.sql @@ -133,8 +133,8 @@ SET @boards_per_segment = (SELECT boardspersegment FROM admin); -- Nadpisujemy tabelę VP na wiecznie remisową (6:6 dla 4 rozdań, 4.5:4.5 dla 3 rozdań, 3/2*n:3/2*n dla n rozdań) UPDATE tabvp SET vpew = 1.5 * @boards_per_segment WHERE dimp = 0; UPDATE tabvp SET vpns = vpew WHERE dimp = 0; -UPDATE matches SET vph = 1.5 * @boards_per_segment; -UPDATE matches SET vpv = vph; +UPDATE matches SET vph = 1.5 * @boards_per_segment WHERE (rnd, tabl) IN (SELECT rnd, tabl FROM patton_boards); +UPDATE matches SET vpv = vph WHERE (rnd, tabl) IN (SELECT rnd, tabl FROM patton_boards); -- Wypełniamy tabelę salda. DELETE FROM patton_sums; |