[phpBB Debug] PHP Warning: in file [ROOT]/includes/crs/crs_misc_functions.php on line 37: mime_content_type(): Empty filename or path
[phpBB Debug] PHP Warning: in file [ROOT]/includes/crs/crs_misc_functions.php on line 37: mime_content_type(): Empty filename or path
Zen Cart 源代码 mysql_upgrade_zencart_152_to_153.sql

Zen Cart 源代码 mysql_upgrade_zencart_152_to_153.sql




下载文件

文件名: mysql_upgrade_zencart_152_to_153.sql
文件类型: Unknown文件
文件大小: 4.79 KiB
MD5: c5a12970c5ff9788ab2425a5d516bdb7

mysql_upgrade_zencart_152_to_153.sql - 关闭高亮
  1. #
  2. # * This SQL script upgrades the core Zen Cart database structure from v1.5.2 to v1.5.3
  3. # *
  4. # * @package Installer
  5. # * @access private
  6. # * @copyright Copyright 2003-2014 Zen Cart Development Team
  7. # * @copyright Portions Copyright 2003 osCommerce
  8. # * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
  9. # * @version GIT: $Id: Author: DrByte  Fri Jun 13 2014  New in v1.5.3 $
  10. #
  11.  
  12. ############ IMPORTANT INSTRUCTIONS ###############
  13. #
  14. # * Zen Cart uses the zc_install/index.php program to do database upgrades
  15. # * This SQL script is intended to be used by running zc_install
  16. # * It is *not* recommended to simply run these statements manually via any other means
  17. # * ie: not via phpMyAdmin or via the Install SQL Patch tool in Zen Cart admin
  18. # * The zc_install program catches possible problems and also handles table-prefixes automatically
  19. # *
  20. # * To use the zc_install program to do your database upgrade:
  21. # * a. Upload the NEWEST zc_install folder to your server
  22. # * b. Surf to zc_install/index.php via your browser
  23. # * c. On the System Inspection page, scroll to the bottom and click on Database Upgrade
  24. # *    NOTE: do NOT click on the "Install" button, because that will erase your database.
  25. # * d. On the Database Upgrade screen, you will be presented with a list of checkboxes for
  26. # *    various Zen Cart versions, with the recommended upgrades already pre-selected.
  27. # * e. Verify the checkboxes, then scroll down and enter your Zen Cart Admin username
  28. # *    and password, and then click on the Upgrade button.
  29. # * f. If any errors occur, you will be notified.  Some warnings can be ignored.
  30. # * g. When done, you will be taken to the Finished page.
  31. #
  32. #####################################################
  33.  
  34. # Set store to Down-For-Maintenance mode.  Must reset manually via admin after upgrade is done.
  35. #UPDATE configuration set configuration_value = 'true' where configuration_key = 'DOWN_FOR_MAINTENANCE';
  36.  
  37. # Clear out active customer sessions
  38. TRUNCATE TABLE whos_online;
  39. TRUNCATE TABLE db_cache;
  40.  
  41. UPDATE configuration set configuration_group_id = 6 where configuration_key in ('PRODUCTS_OPTIONS_TYPE_SELECT', 'UPLOAD_PREFIX', 'TEXT_PREFIX');
  42.  
  43. #ISO Updates:
  44. UPDATE countries SET countries_name = 'Libya' WHERE countries_iso_code_3 = 'LBY';
  45. UPDATE countries SET countries_name = 'Palestine, State of' WHERE countries_iso_code_3 = 'PSE';
  46. INSERT INTO countries (countries_id, countries_name, countries_iso_code_2, countries_iso_code_3, address_format_id) VALUES (246,'South Sudan','SS','SSD','1');
  47.  
  48.  
  49. ALTER TABLE admin MODIFY admin_pass VARCHAR( 255 ) NOT NULL DEFAULT '';
  50. ALTER TABLE admin MODIFY prev_pass1 VARCHAR( 255 ) NOT NULL DEFAULT '';
  51. ALTER TABLE admin MODIFY prev_pass2 VARCHAR( 255 ) NOT NULL DEFAULT '';
  52. ALTER TABLE admin MODIFY prev_pass3 VARCHAR( 255 ) NOT NULL DEFAULT '';
  53. ALTER TABLE admin MODIFY reset_token VARCHAR( 255 ) NOT NULL DEFAULT '';
  54. ALTER TABLE customers MODIFY customers_password VARCHAR( 255 ) NOT NULL DEFAULT '';
  55.  
  56. UPDATE configuration set configuration_description = 'Record the database queries to files in the system /logs/ folder. USE WITH CAUTION. This can seriously degrade your site performance and blow out your disk space storage quotas.<br><strong>Enabling this makes your site NON-COMPLIANT with PCI DSS rules, thus invalidating any certification.</strong>' where configuration_key = 'STORE_DB_TRANSACTIONS';
  57.  
  58.  
  59.  
  60. #############
  61.  
  62. #### VERSION UPDATE STATEMENTS
  63. ## THE FOLLOWING 2 SECTIONS SHOULD BE THE "LAST" ITEMS IN THE FILE, so that if the upgrade fails prematurely, the version info is not updated.
  64. ##The following updates the version HISTORY to store the prior version info (Essentially "moves" the prior version info from the "project_version" to "project_version_history" table
  65. #NEXT_X_ROWS_AS_ONE_COMMAND:3
  66. INSERT INTO project_version_history (project_version_key, project_version_major, project_version_minor, project_version_patch, project_version_date_applied, project_version_comment)
  67. SELECT project_version_key, project_version_major, project_version_minor, project_version_patch1 as project_version_patch, project_version_date_applied, project_version_comment
  68. FROM project_version;
  69.  
  70. ## Now set to new version
  71. UPDATE project_version SET project_version_major='1', project_version_minor='5.3', project_version_patch1='', project_version_patch1_source='', project_version_patch2='', project_version_patch2_source='', project_version_comment='Version Update 1.5.2->1.5.3', project_version_date_applied=now() WHERE project_version_key = 'Zen-Cart Main';
  72. UPDATE project_version SET project_version_major='1', project_version_minor='5.3', project_version_patch1='', project_version_patch1_source='', project_version_patch2='', project_version_patch2_source='', project_version_comment='Version Update 1.5.2->1.5.3', project_version_date_applied=now() WHERE project_version_key = 'Zen-Cart Database';
  73.  
  74. #####  END OF UPGRADE SCRIPT
  75.  
  76.  


cron