OSDN Git Service

Use more proper formula to calculate the number of bigram entries.
[pgbigm/pg_bigm.git] / html / pg_bigm_en-1-1.html
index a2c69e4..38adc7d 100644 (file)
@@ -85,7 +85,7 @@ For example, x.y is 1.1 and YYYYMMDD is 20131122 if the file of the version 1.1
   <td>Supported (version 1.1 or later)</td></tr>
 <tr><td>Maximum indexed column size</td>
   <td nowrap>238,609,291 Bytes (~228MB)</td>
-  <td nowrap>71,582,785 Bytes (~68MB)</td></tr>
+  <td nowrap>107,374,180 Bytes (~102MB)</td></tr>
 </tbody>
 </table>
 
@@ -495,13 +495,13 @@ Please see <a href="http://www.postgresql.org/docs/current/static/gin-implementa
 <h2 id="limitations">Limitations</h2>
 <h3 id="indexed_column_size">Indexed Column Size</h3>
 
-<p>The size of the column indexed by bigm GIN index cannot exceed 71,582,785 Bytes (~68MB). Any attempt to enter larger values will result in an error. </p>
+<p>The size of the column indexed by bigm GIN index cannot exceed 107,374,180 Bytes (~102MB). Any attempt to enter larger values will result in an error. </p>
 
 <pre>
 =# CREATE TABLE t1 (description text);
 =# CREATE INDEX t1_idx ON t1 USING gin (description gin_bigm_ops);
-=# INSERT INTO t1 SELECT repeat('A', 71582786);
-ERROR:  invalid memory alloc request size 1073741824
+=# INSERT INTO t1 SELECT repeat('A', 107374181);
+ERROR:  out of memory
 </pre>
 
 <p>pg_trgm also has this limitation. However, the maximum size in the case of trgm indexed column is 238,609,291 Bytes (~228MB).</p>