журнал (shhh) wrote in changelog,
журнал
shhh
changelog

[ljcom] r12397: LJSUP-13171: Rename table 'blocking' to ...

Committer: nnikulochkina
LJSUP-13171: Rename table 'blocking' to 'wallet_blocking'
U   trunk/bin/upgrading/update-db-local.pl
Modified: trunk/bin/upgrading/update-db-local.pl
===================================================================
--- trunk/bin/upgrading/update-db-local.pl	2012-08-01 15:16:22 UTC (rev 12396)
+++ trunk/bin/upgrading/update-db-local.pl	2012-08-01 15:22:11 UTC (rev 12397)
@@ -1881,8 +1881,8 @@
 )
 EOC
 
-register_tablecreate('blocking', <<'EOC');
-CREATE TABLE `blocking` (
+register_tablecreate('wallet_blocking', <<'EOC');
+CREATE TABLE `wallet_blocking` (
   `blid` int(11) unsigned NOT NULL AUTO_INCREMENT,
   `userid` int(11) unsigned NOT NULL,
   `rcptid` int(11) unsigned NOT NULL,
@@ -1929,8 +1929,8 @@
 )
 EOC
 
-register_tablecreate('blocking_history', <<'EOC');
-CREATE TABLE `blocking_history` (
+register_tablecreate('wallet_blocking_history', <<'EOC');
+CREATE TABLE `wallet_blocking_history` (
   `logid` int(11) NOT NULL AUTO_INCREMENT,
   `userid` int(11) NOT NULL default '0',
   `blid` int(11) NOT NULL default '0',
@@ -1938,6 +1938,7 @@
   `accid` int(11) NOT NULL default '0',
   `action` char(1) NOT NULL DEFAULT '',
   `qty` bigint(20) NOT NULL,
+  `purpose` char(1) DEFAULT NULL,
   `timestamp` int(11) NOT NULL DEFAULT '0',
   PRIMARY KEY  (`logid`),
   KEY `userid` (`userid`,`timestamp`),
@@ -2565,6 +2566,13 @@
         });
     }
 
+    unless (column_type("user_account_history", "purpose")) {
+        do_alter("user_account_history", qq{
+            ALTER TABLE user_account_history
+                ADD COLUMN purpose char(1) default NULL;
+        });
+    }
+
 });
 
 1;  # true

Tags: ljcom, nikulochkina, nnikulochkina, pl
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments