[TYPO3-core] RFC: Fix bug #9639: DB Analyzer / Compare Tool can't handle the upgrade of the cache tables

Oliver Hader oliver at typo3.org
Wed Nov 12 19:41:45 CET 2008


FYI: Committed to SVN Trunk (rev. 4459)
The commit for TYPO3_4-2 is still pending!

olly


Michael Stucki schrieb:
> Hi!
> 
> This is SVN patch request.
> 
> Type: bugfix
> 
> Branches: Trunk / TYPO3_4-2
> 
> BT reference: http://bugs.typo3.org/view.php?id=9639
> 
> Problem:
> When changing the SQL-definitions of cache_hash and cache_pagesection,
> the updater will always fail.
> 
> There are two reasons for this:
> 1. The table must be cleared to make sure that the keys are unique. This
> is no problem for cache_* tables.
> 2. auto_increment must be set _after_ the primary key was created.
> However, the primary key can only be created if the field already
> exists. So the field must be created in two steps (first without the
> "auto_increment" option).
> 
> Solution:
> Attached is a patch that fixes both issues. However it will require to
> go through the update twice:
> 1st step:
> - Remove all fields which are no longer used (drop them really, not just
> rename)
> - Clear cache_* and index_* tables which are going to be modified
> - Create new fields (without "auto_increment" option)
> - Create keys
> 
> 2nd step:
> - Add "auto_increment" option
> 
> Regards
-- 
Oliver Hader
TYPO3 4.3 Release Manager


More information about the TYPO3-team-core mailing list