[Vtigercrm-commits] [vtiger-commits] r10523 - in /vtigercrm/branches/5.0.3/modules/Migration: DBChanges/42P2_to_50.php DBChanges/501_to_502.php DBChanges/502_to_503rc2.php DBChanges/503rc2_to_503.php PatchApply.php versions.php
vtigercrm-commits at vtiger.fosslabs.com
vtigercrm-commits at vtiger.fosslabs.com
Thu Mar 29 06:23:38 EDT 2007
Author: saraj
Date: Thu Mar 29 04:23:29 2007
New Revision: 10523
Log:
* Added 503 RC2 migration in the script and added some debug logs
Added:
vtigercrm/branches/5.0.3/modules/Migration/DBChanges/502_to_503rc2.php (with props)
vtigercrm/branches/5.0.3/modules/Migration/DBChanges/503rc2_to_503.php
Modified:
vtigercrm/branches/5.0.3/modules/Migration/DBChanges/42P2_to_50.php
vtigercrm/branches/5.0.3/modules/Migration/DBChanges/501_to_502.php
vtigercrm/branches/5.0.3/modules/Migration/PatchApply.php
vtigercrm/branches/5.0.3/modules/Migration/versions.php
Modified: vtigercrm/branches/5.0.3/modules/Migration/DBChanges/42P2_to_50.php
==============================================================================
--- vtigercrm/branches/5.0.3/modules/Migration/DBChanges/42P2_to_50.php (original)
+++ vtigercrm/branches/5.0.3/modules/Migration/DBChanges/42P2_to_50.php Thu Mar 29 04:23:29 2007
@@ -19,18 +19,15 @@
global $query_count, $success_query_count, $failure_query_count;
global $success_query_array, $failure_query_array;
+$migrationlog->debug("\n\nDB Changes from 4.2.x to 5.0 GA -------- Starts \n\n");
+
//Added to put prefix vtiger_ in some of the columns in tables which are used for CV and Reports and field -- 23-06-06
$migrationlog->debug("Going to rename the table names with prefix vtiger_");
include("modules/Migration/rename_tables.php");
$migrationlog->debug("Renaming the table names with prefix vtiger_ has been finished");
-
-
-
-
$migrationlog->debug("Database Modifications for 4.2 Patch2 ==> 5.0(Alpha) Dev 3 Starts here.");
-
//These changes have been made in 4.2.3. The following queries have been included who has run the migration from 4.2 Patch2
@@ -4052,6 +4049,7 @@
}
+$migrationlog->debug("\n\nDB Changes from 4.2.x to 5.0 GA -------- Ends \n\n");
//Added to get the conversion rate and update for all records
@@ -4118,7 +4116,7 @@
<td width="70%">'.$query.'</td>
</tr>';
$failure_query_array[$failure_query_count++] = $query;
- $migrationlog->debug("Query Failed ==> $query");
+ $migrationlog->debug("Query Failed ==> $query \n Error is ==> [".$conn->database->ErrorNo()."]".$conn->database->ErrorMsg());
//$migrationlog->debug("Error is ==> ".$conn->ErrorMsg());
}
}
Modified: vtigercrm/branches/5.0.3/modules/Migration/DBChanges/501_to_502.php
==============================================================================
--- vtigercrm/branches/5.0.3/modules/Migration/DBChanges/501_to_502.php (original)
+++ vtigercrm/branches/5.0.3/modules/Migration/DBChanges/501_to_502.php Thu Mar 29 04:23:29 2007
@@ -12,6 +12,8 @@
//5.0.2 database changes - added on 27-10-06
global $adb;
+
+$migrationlog->debug("\n\nDB Changes from 5.0.1 to 5.0.2 -------- Starts \n\n");
//Query added to show Manufacturer field in Products module
ExecuteQuery("update vtiger_field set displaytype=1,block=31 where tabid=14 and block=1");
@@ -63,5 +65,6 @@
//echo "<br><font color='red'> 5.0/5.0.1 ==> 5.0.2 Database changes has been done.</font><br>";
+$migrationlog->debug("\n\nDB Changes from 5.0.1 to 5.0.2 -------- Ends \n\n");
?>
Modified: vtigercrm/branches/5.0.3/modules/Migration/PatchApply.php
==============================================================================
--- vtigercrm/branches/5.0.3/modules/Migration/PatchApply.php (original)
+++ vtigercrm/branches/5.0.3/modules/Migration/PatchApply.php Thu Mar 29 04:23:29 2007
@@ -10,6 +10,7 @@
********************************************************************************/
include("modules/Migration/versions.php");
+$migrationlog =& LoggerManager::getLogger('MIGRATION');
//global $vtiger_current_version;
if($_REQUEST['source_version'] != '')
@@ -76,8 +77,11 @@
echo '<br><br><b style="color:#FF0000">Failed Queries Log</b>
<div id="failedLog" style="border:1px solid #666666;width:90%;position:relative;height:200px;overflow:auto;left:5%;top:10px;">';
- foreach($failure_query_array as $failed_query)
- echo '<br><font color="red">'.$failed_query.';</font>';
+ if(is_array($failure_query_array))
+ foreach($failure_query_array as $failed_query)
+ echo '<br><font color="red">'.$failed_query.';</font>';
+ else
+ echo '<br> No queries failed during Patch Update.';
echo '<br></div>';
//echo "Failed Queries ==> <pre>";print_r($failure_query_array);echo '</pre>';
@@ -109,6 +113,7 @@
<td width="80%">'.$query.'</td>
</tr>';
$success_query_array[$success_query_count++] = $query;
+ $migrationlog->debug("Query Success ==> $query");
}
else
{
@@ -119,16 +124,9 @@
<td width="70%">'.$query.'</td>
</tr>';
$failure_query_array[$failure_query_count++] = $query;
+ $migrationlog->debug("Query Failed ==> $query \n Error is ==> [".$adb->database->ErrorNo()."]".$adb->database->ErrorMsg());
}
}
-
-
-
-
-
-
-
-
?>
Modified: vtigercrm/branches/5.0.3/modules/Migration/versions.php
==============================================================================
--- vtigercrm/branches/5.0.3/modules/Migration/versions.php (original)
+++ vtigercrm/branches/5.0.3/modules/Migration/versions.php Thu Mar 29 04:23:29 2007
@@ -16,6 +16,7 @@
"50"=>"5.0",
"501"=>"5.0.1",
"502"=>"5.0.2",
+ "503rc2"=>"5.0.3 RC2",
);
$current_version = '503';
More information about the vtigercrm-commits
mailing list