Commit 222d2bb9e3af8f9bfef86aa953fb24d574fd85ab

Authored by kevin_fourie
1 parent ec26265b

Merged in from STABLE trunk...

KTS-3592
"Upgrade failed from 346 to 353."
Fixed. A function now runs before the upgrades to add auto_increment to the existing tables.

Committed by: Megan Watson
Reviewed by: Conrad Vermeulen


git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/STABLE/branches/3.5.3-Release-Branch@9090 c91229c3-7414-0410-bfa2-8a42b809f60b
sql/mysql/upgrade/3.5.3/add_autoinc-5.sql deleted
1   -select @id :=max(id)+1 from plugins;
2   -update plugins set id = @id where id = 0;
3   -select @id :=max(id)+1 from upgrades;
4   -update upgrades set id = @id where id = 0;
5   -alter table active_sessions change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
6   -alter table archive_restoration_request change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
7   -alter table archiving_settings change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
8   -alter table archiving_type_lookup change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
9   -alter table authentication_sources change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
10   -alter table column_entries change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
11   -alter table dashlet_disables change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
12   -alter table data_types change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
13   -alter table discussion_comments change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
14   -alter table discussion_threads change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
15   -alter table document_archiving_link change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
16   -alter table document_content_version change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
17   -alter table document_fields change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
18   -alter table document_fields_link change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
19   -alter table document_incomplete change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
20   -alter table document_link change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
21   -alter table document_link_types change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
22   -alter table document_metadata_version change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
23   -alter table document_role_allocations change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
24   -alter table document_subscriptions change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
25   -alter table document_transaction_types_lookup change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
26   -alter table document_transactions change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
27   -alter table document_type_fields_link change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
28   -alter table document_type_fieldsets_link change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
29   -alter table document_types_lookup change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
30   -alter table documents change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
31   -alter table field_behaviours change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
32   -alter table field_value_instances change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
33   -alter table fieldsets change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
34   -alter table folder_doctypes_link change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
35   -alter table folder_subscriptions change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
36   -alter table folder_transactions change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
37   -alter table folders change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
38   -alter table folders_users_roles_link change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
39   -alter table groups_groups_link change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
40   -alter table groups_lookup change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
41   -alter table help change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
42   -alter table help_replacement change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
43   -alter table interceptor_instances change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
44   -alter table links change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
45   -alter table metadata_lookup change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
46   -alter table metadata_lookup_tree change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
47   -alter table mime_extractors change `id` `id` mediumint(9) NOT NULL AUTO_INCREMENT;
48   -alter table mime_documents change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
49   -alter table mime_types change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
50   -alter table news change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
51   -alter table notifications change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
52   -alter table organisations_lookup change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
53   -alter table permission_assignments change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
54   -alter table permission_descriptors change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
55   -alter table permission_dynamic_conditions change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
56   -alter table permission_lookup_assignments change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
57   -alter table permission_lookups change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
58   -alter table permission_objects change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
59   -alter table permissions change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
60   -alter table plugin_helper change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
61   -alter table plugin_rss change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
62   -alter table plugins change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
63   -alter table role_allocations change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
64   -alter table roles change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
65   -alter table saved_searches change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
66   -alter table scheduler_tasks change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
67   -alter table search_saved change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
68   -alter table status_lookup change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
69   -alter table system_settings change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
70   -alter table tag_words change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
71   -alter table time_period change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
72   -alter table time_unit_lookup change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
73   -alter table units_lookup change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
74   -alter table units_organisations_link change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
75   -alter table upgrades change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
76   -alter table user_history change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
77   -alter table users change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
78   -alter table users_groups_link change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
79   -alter table workflow_state_permission_assignments change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
80   -alter table workflow_states change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
81   -alter table workflow_transitions change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
82   -alter table workflow_trigger_instances change `id` `id` int (11) NOT NULL AUTO_INCREMENT;
83   -alter table workflows change `id` `id` int (11) NOT NULL AUTO_INCREMENT;