From ef2cc85c8caf3f2c73710ca1db6101e3b65376a6 Mon Sep 17 00:00:00 2001 From: james Date: Thu, 29 Nov 2007 18:25:56 +0000 Subject: [PATCH] Rollover the extern award/prize identifiers from year to year --- config/rollover.php | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/config/rollover.php b/config/rollover.php index e7346576..0c4cd655 100644 --- a/config/rollover.php +++ b/config/rollover.php @@ -147,7 +147,7 @@ echo mysql_error(); while($r=mysql_fetch_object($q)) { - mysql_query("INSERT INTO award_awards (award_sponsors_id,award_types_id,name,criteria,description,presenter,`order`,year,excludefromac,cwsfaward) VALUES ( + mysql_query("INSERT INTO award_awards (award_sponsors_id,award_types_id,name,criteria,description,presenter,`order`,year,excludefromac,cwsfaward,external_identifier,external_postback,award_sources_id) VALUES ( '".mysql_escape_string($r->award_sponsors_id)."', '".mysql_escape_string($r->award_types_id)."', '".mysql_escape_string($r->name)."', @@ -157,7 +157,11 @@ '".mysql_escape_string($r->order)."', '".mysql_escape_string($newfairyear)."', '".mysql_escape_string($r->excludefromac)."', - '".mysql_escape_string($r->cwsfaward)."')"); + '".mysql_escape_string($r->cwsfaward)."', + '".mysql_escape_string($r->external_identifier)."', + '".mysql_escape_string($r->external_postaback)."', + '".mysql_escape_string($r->award_sources_id)."' + )"); $award_awards_id=mysql_insert_id(); $q2=mysql_query("SELECT * FROM award_awards_projectcategories WHERE year='$currentfairyear' AND award_awards_id='$r->id'"); @@ -187,7 +191,7 @@ echo mysql_error(); while($r2=mysql_fetch_object($q2)) { - mysql_query("INSERT INTO award_prizes (award_awards_id,cash,scholarship,`value`,prize,number,`order`,year,excludefromac,trophystudentkeeper,trophystudentreturn,trophyschoolkeeper,trophyschoolreturn) VALUES ( + mysql_query("INSERT INTO award_prizes (award_awards_id,cash,scholarship,`value`,prize,number,`order`,year,excludefromac,trophystudentkeeper,trophystudentreturn,trophyschoolkeeper,trophyschoolreturn,external_identifier) VALUES ( '".mysql_escape_string($award_awards_id)."', '".mysql_escape_string($r2->cash)."', '".mysql_escape_string($r2->scholarship)."', @@ -200,7 +204,8 @@ '".mysql_escape_string($r2->trophystudentkeeper)."', '".mysql_escape_string($r2->trophystudentreturn)."', '".mysql_escape_string($r2->trophyschoolkeeper)."', - '".mysql_escape_string($r2->trophyschoolreturn)."' + '".mysql_escape_string($r2->trophyschoolreturn)."', + '".mysql_escape_string($r2->external_identifier)."' )"); } }