<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="http://www.zarafa.com/wiki/skins/common/feed.css?270"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://www.zarafa.com/wiki/index.php?title=Enabling_more_than_32768_entries_in_users/stores_table&amp;feed=atom&amp;action=history</id>
		<title>Enabling more than 32768 entries in users/stores table - Revision history</title>
		<link rel="self" type="application/atom+xml" href="http://www.zarafa.com/wiki/index.php?title=Enabling_more_than_32768_entries_in_users/stores_table&amp;feed=atom&amp;action=history"/>
		<link rel="alternate" type="text/html" href="http://www.zarafa.com/wiki/index.php?title=Enabling_more_than_32768_entries_in_users/stores_table&amp;action=history"/>
		<updated>2013-05-25T20:02:55Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.16.0</generator>

	<entry>
		<id>http://www.zarafa.com/wiki/index.php?title=Enabling_more_than_32768_entries_in_users/stores_table&amp;diff=2064&amp;oldid=prev</id>
		<title>Ddebyttere at 08:22, 31 May 2012</title>
		<link rel="alternate" type="text/html" href="http://www.zarafa.com/wiki/index.php?title=Enabling_more_than_32768_entries_in_users/stores_table&amp;diff=2064&amp;oldid=prev"/>
				<updated>2012-05-31T08:22:50Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: white; color:black;&quot;&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
			&lt;col class='diff-marker' /&gt;
			&lt;col class='diff-content' /&gt;
		&lt;tr valign='top'&gt;
		&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;← Older revision&lt;/td&gt;
		&lt;td colspan='2' style=&quot;background-color: white; color:black;&quot;&gt;Revision as of 08:22, 31 May 2012&lt;/td&gt;
		&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 42:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 42:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;You can fix this by issue'ing the following queries (can be done online) in this order:&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;You can fix this by issue'ing the following queries (can be done online) in this order:&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;pre&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;pre&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;alter table stores modify company &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;INT&lt;/del&gt;(11) &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;UNSIGNED&lt;/del&gt;;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;alter table stores modify company &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;int&lt;/ins&gt;(11) &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;unsigned NOT NULL default 0;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;alter table stores modify user_id int(11) unsigned NOT NULL default 0;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;nbsp;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;alter table stores modify id int(11) unsigned NOT NULL auto_increment&lt;/ins&gt;;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;alter table stores modify user_id INT(11) UNSIGNED;&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;alter table users modify company &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;int&lt;/ins&gt;(11) &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;unsigned NOT NULL default 0&lt;/ins&gt;;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;alter table users modify id &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;int&lt;/ins&gt;(11) &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;unsigned NOT NULL &lt;/ins&gt;auto_increment;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;alter table stores modify id INT(11) UNSIGNED auto_increment;&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;alter table users modify company &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;INT&lt;/del&gt;(11) &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;UNSIGNED&lt;/del&gt;;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;-&lt;/td&gt;&lt;td style=&quot;background: #ffa; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;alter table users modify id &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;INT&lt;/del&gt;(11) &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;UNSIGNED &lt;/del&gt;auto_increment;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;background: #cfc; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;/pre&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background: #eee; color:black; font-size: smaller;&quot;&gt;&lt;div&gt;&amp;lt;/pre&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Ddebyttere</name></author>	</entry>

	<entry>
		<id>http://www.zarafa.com/wiki/index.php?title=Enabling_more_than_32768_entries_in_users/stores_table&amp;diff=1900&amp;oldid=prev</id>
		<title>Msartor: Created page with &quot;When you have ever ran an older 6.40 version of ZCP, it could be that some of the database field types, in the users and stores tables, are smallints, which means that they canno...&quot;</title>
		<link rel="alternate" type="text/html" href="http://www.zarafa.com/wiki/index.php?title=Enabling_more_than_32768_entries_in_users/stores_table&amp;diff=1900&amp;oldid=prev"/>
				<updated>2012-02-06T11:25:04Z</updated>
		
		<summary type="html">&lt;p&gt;Created page with &amp;quot;When you have ever ran an older 6.40 version of ZCP, it could be that some of the database field types, in the users and stores tables, are smallints, which means that they canno...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;When you have ever ran an older 6.40 version of ZCP, it could be that some of the database field types, in the users and stores tables, are smallints, which means that they cannot hold more than 32768 entries:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mysql&amp;gt; describe users;&lt;br /&gt;
+-------------+----------------+------+-----+---------+----------------+&lt;br /&gt;
| Field       | Type           | Null | Key | Default | Extra          |&lt;br /&gt;
+-------------+----------------+------+-----+---------+----------------+&lt;br /&gt;
| id          | smallint(11)   | NO   | PRI | NULL    | auto_increment |&lt;br /&gt;
| externid    | blob           | YES  | MUL | NULL    |                |&lt;br /&gt;
| objectclass | int(11)        | NO   |     | 0       |                |&lt;br /&gt;
| signature   | varbinary(255) | NO   |     | 0       |                |&lt;br /&gt;
| company     | smallint(11)   | NO   |     | 0       |                |&lt;br /&gt;
+-------------+----------------+------+-----+---------+----------------+&lt;br /&gt;
5 rows in set (0.00 sec)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
mysql&amp;gt; describe stores;&lt;br /&gt;
+--------------+-----------------------+------+-----+---------+----------------+&lt;br /&gt;
| Field        | Type                  | Null | Key | Default | Extra          |&lt;br /&gt;
+--------------+-----------------------+------+-----+---------+----------------+&lt;br /&gt;
| id           | smallint(6) unsigned  | NO   | UNI | NULL    | auto_increment |&lt;br /&gt;
| hierarchy_id | int(11) unsigned      | NO   | PRI | 0       |                |&lt;br /&gt;
| user_id      | smallint(6) unsigned  | NO   | PRI | 0       |                |&lt;br /&gt;
| user_name    | varchar(255)          | NO   |     |         |                |&lt;br /&gt;
| company      | smallint(11) unsigned | NO   |     | 0       |                |&lt;br /&gt;
| guid         | blob                  | NO   |     | NULL    |                |&lt;br /&gt;
| type         | smallint(6) unsigned  | NO   | PRI | 0       |                |&lt;br /&gt;
+--------------+-----------------------+------+-----+---------+----------------+&lt;br /&gt;
7 rows in set (0.00 sec)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This will result in errors in the server.log, like:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
0x002aaac39fb6a0: SQL Failed: Duplicate entry '32767' for key 'PRIMARY', Query: &amp;quot;INSERT INTO users (externid, objectclass, signature) VALUES('1248', 196610, '20120202103220Z')&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In NEW installations this is fixed. But if you have ever used an older 6.40 version it could be that these fields need to be modified. First check with the above queries if it you really need to modify your tables. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You can fix this by issue'ing the following queries (can be done online) in this order:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
alter table stores modify company INT(11) UNSIGNED;&lt;br /&gt;
&lt;br /&gt;
alter table stores modify user_id INT(11) UNSIGNED;&lt;br /&gt;
&lt;br /&gt;
alter table stores modify id INT(11) UNSIGNED auto_increment;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
alter table users modify company INT(11) UNSIGNED;&lt;br /&gt;
&lt;br /&gt;
alter table users modify id INT(11) UNSIGNED auto_increment;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Msartor</name></author>	</entry>

	</feed>