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 00000000000..552fe7dbb40 --- /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 23ce8fa2273..35b59fdd338 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