From bfd925832673f8ba506b0852a62b0a5107e60bca Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Thu, 28 Jun 2012 20:46:46 +0530 Subject: [PATCH] fix in cacheitem table --- erpnext/patches/june_2012/cache_item_table.py | 11 +++++++++++ erpnext/patches/patch_list.py | 5 +++++ 2 files changed, 16 insertions(+) create mode 100644 erpnext/patches/june_2012/cache_item_table.py diff --git a/erpnext/patches/june_2012/cache_item_table.py b/erpnext/patches/june_2012/cache_item_table.py new file mode 100644 index 0000000000..552fe7dbb4 --- /dev/null +++ b/erpnext/patches/june_2012/cache_item_table.py @@ -0,0 +1,11 @@ +def execute(): + """drop and create __CacheItem table again""" + import webnotes + webnotes.conn.commit() + webnotes.conn.sql("drop table __CacheItem") + webnotes.conn.sql("""create table __CacheItem( + `key` VARCHAR(180) NOT NULL PRIMARY KEY, + `value` LONGTEXT, + `expires_on` DATETIME + ) ENGINE=MyISAM DEFAULT CHARSET=utf8""") + webnotes.conn.begin() \ No newline at end of file diff --git a/erpnext/patches/patch_list.py b/erpnext/patches/patch_list.py index 23ce8fa227..35b59fdd33 100644 --- a/erpnext/patches/patch_list.py +++ b/erpnext/patches/patch_list.py @@ -457,4 +457,9 @@ patch_list = [ 'patch_file': 'delete_about_contact', 'description': "delete depracated doctypes of website module" }, + { + 'patch_module': 'patches.june_2012', + 'patch_file': 'cache_item_table', + 'description': "create cache item table again" + }, ] \ No newline at end of file