[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [6472] Catch: alter MySQL reserved fieldname
From: |
Sigurd Nes |
Subject: |
[Fmsystem-commits] [6472] Catch: alter MySQL reserved fieldname |
Date: |
Mon, 11 Oct 2010 21:14:01 +0000 |
Revision: 6472
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=6472
Author: sigurdne
Date: 2010-10-11 21:14:00 +0000 (Mon, 11 Oct 2010)
Log Message:
-----------
Catch: alter MySQL reserved fieldname
Modified Paths:
--------------
trunk/catch/inc/class.soconfig.inc.php
trunk/catch/setup/setup.inc.php
trunk/catch/setup/tables_current.inc.php
trunk/catch/setup/tables_update.inc.php
Modified: trunk/catch/inc/class.soconfig.inc.php
===================================================================
--- trunk/catch/inc/class.soconfig.inc.php 2010-10-11 16:37:55 UTC (rev
6471)
+++ trunk/catch/inc/class.soconfig.inc.php 2010-10-11 21:14:00 UTC (rev
6472)
@@ -107,7 +107,7 @@
'id' => $this->db->f('id'),
'name' => $this->db->f('name', true),
'descr' => $this->db->f('descr', true),
- 'schema' =>
$this->db->f('schema')
+ 'schema' =>
$this->db->f('schema_')
);
}
@@ -129,7 +129,7 @@
'id' => $id,
'name' => $this->db->f('name',
true),
'descr' =>
$this->db->f('descr', true),
- 'schema' =>
$this->db->f('schema')
+ 'schema' =>
$this->db->f('schema_')
);
}
return $values;
@@ -172,7 +172,7 @@
);
$insert_values =
$this->db->validate_insert($insert_values);
- $this->db->query("INSERT INTO fm_catch_config_type
(id,name,descr,schema) "
+ $this->db->query("INSERT INTO fm_catch_config_type
(id,name,descr,schema_) "
. "VALUES ($insert_values)",__LINE__,__FILE__);
$receipt['message'][]=array('msg'=>lang('config type
has been saved'));
Modified: trunk/catch/setup/setup.inc.php
===================================================================
--- trunk/catch/setup/setup.inc.php 2010-10-11 16:37:55 UTC (rev 6471)
+++ trunk/catch/setup/setup.inc.php 2010-10-11 21:14:00 UTC (rev 6472)
@@ -27,7 +27,7 @@
*/
$setup_info['catch']['name'] = 'catch';
- $setup_info['catch']['version'] = '0.9.17.508';
+ $setup_info['catch']['version'] = '0.9.17.509';
$setup_info['catch']['app_order'] = 20;
$setup_info['catch']['enable'] = 1;
$setup_info['catch']['globals_checked'] = True;
Modified: trunk/catch/setup/tables_current.inc.php
===================================================================
--- trunk/catch/setup/tables_current.inc.php 2010-10-11 16:37:55 UTC (rev
6471)
+++ trunk/catch/setup/tables_current.inc.php 2010-10-11 21:14:00 UTC (rev
6472)
@@ -96,7 +96,7 @@
'id' => array('type' => 'int','precision' =>
4,'nullable' => False),
'name' => array('type' => 'varchar',
'precision' => 50,'nullable' => False),
'descr' => array('type' => 'varchar',
'precision' => 200,'nullable' => true),
- 'schema' => array('type' => 'varchar',
'precision' => 10,'nullable' => false)
+ 'schema_' => array('type' => 'varchar',
'precision' => 10,'nullable' => false)
),
'pk' => array('id'),
'fk' => array(),
Modified: trunk/catch/setup/tables_update.inc.php
===================================================================
--- trunk/catch/setup/tables_update.inc.php 2010-10-11 16:37:55 UTC (rev
6471)
+++ trunk/catch/setup/tables_update.inc.php 2010-10-11 21:14:00 UTC (rev
6472)
@@ -285,3 +285,22 @@
return $GLOBALS['setup_info']['catch']['currentver'];
}
}
+ /**
+ * Update property version from 0.9.17.508 to 0.9.17.509
+ * Rename reserved fieldname to allow MySQL
+ *
+ */
+
+ $test[] = '0.9.17.508';
+ function catch_upgrade0_9_17_508()
+ {
+ $GLOBALS['phpgw_setup']->oProc->m_odb->transaction_begin();
+
+
$GLOBALS['phpgw_setup']->oProc->RenameColumn('fm_catch_config_type','schema','schema_');
+
+ if($GLOBALS['phpgw_setup']->oProc->m_odb->transaction_commit())
+ {
+ $GLOBALS['setup_info']['catch']['currentver'] =
'0.9.17.509';
+ return $GLOBALS['setup_info']['catch']['currentver'];
+ }
+ }
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [6472] Catch: alter MySQL reserved fieldname,
Sigurd Nes <=