<!DOCTYPE html>
<html>
<head>
</head>
<body>
<dl style="line-height: 1.5; margin-left: 2em">
<dt style="clear: both; float: left; font-weight: bold; width: 8em">Author</dt>
<dd style="margin-left: 8.5em">Tetsuro IKEDA <mir@uc.(none)></dd>
<dt style="clear: both; float: left; font-weight: bold; width: 8em">Date</dt>
<dd style="margin-left: 8.5em">2010-06-11 16:14:24 +0900 (Fri, 11 Jun 2010)</dd>
<dt style="clear: both; float: left; font-weight: bold; width: 8em">New Revision</dt>
<dd style="margin-left: 8.5em"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c">91c65f833d6c66ec71675db5247acffd1784d30c</a></dd>
<dt style="clear: both; float: left; font-weight: bold; width: 8em">Log</dt>
<dd style="margin-left: 8.5em"><pre style="border: 1px solid #aaa; font-family: Consolas, Menlo, "Liberation Mono", Courier, monospace; line-height: 1.2; padding: 0.5em">disable secondary keys.</pre></dd>
<dt style="clear: both; float: left; font-weight: bold; width: 8em">Modified files</dt>
<dd style="margin-left: 8.5em">
<ul>
<li><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#diff-0">ha_mroonga.cc</a></li>
</ul>
</dd>
</dl>
<div class="diff-section" style="clear: both">
<table style="border-collapse: collapse; border: 1px solid #aaa">
<thead>
<tr class="diff-header" style="border: 1px solid #aaa">
<td colspan="3">
<pre style="border: 0; font-family: Consolas, Menlo, "Liberation Mono", Courier, monospace; line-height: 1.2; margin: 0; padding: 0.5em; white-space: normal"><span class="diff-header" style="background-color: #eaf2f5; color: #999999; display: block; white-space: pre"> Modified: ha_mroonga.cc (+8 -1)</span>
<span class="diff-header-mark" style="background-color: #eaf2f5; color: #999999; display: block; white-space: pre">===================================================================</span>
</pre>
</td>
</tr>
</thead>
<tbody>
<tr>
<th class="diff-line-number" style="border: 1px solid #aaa">
<pre style="border: 0; font-family: Consolas, Menlo, "Liberation Mono", Courier, monospace; line-height: 1.2; margin: 0; padding: 0.5em; white-space: normal"><span class="diff-line-number-hunk-header" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0L672">...</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0L673">673</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0L674">674</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0L675">675</a></span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre"> </span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre"> </span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre"> </span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre"> </span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre"> </span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre"> </span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre"> </span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0L676">676</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0L677">677</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0L678">678</a></span>
<span class="diff-line-number-hunk-header" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0L679">...</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0L680">680</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0L681">681</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0L682">682</a></span>
<span class="diff-line-number-deleted" style="background-color: #ffaaaa; color: #000000; display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0L683">683</a></span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre"> </span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0L684">684</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0L685">685</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0L686">686</a></span>
</pre>
</th>
<th class="diff-line-number" style="border: 1px solid #aaa">
<pre style="border: 0; font-family: Consolas, Menlo, "Liberation Mono", Courier, monospace; line-height: 1.2; margin: 0; padding: 0.5em; white-space: normal"><span class="diff-line-number-hunk-header" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R672">...</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R673">673</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R674">674</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R675">675</a></span>
<span class="diff-line-number-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R676">676</a></span>
<span class="diff-line-number-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R677">677</a></span>
<span class="diff-line-number-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R678">678</a></span>
<span class="diff-line-number-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R679">679</a></span>
<span class="diff-line-number-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R680">680</a></span>
<span class="diff-line-number-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R681">681</a></span>
<span class="diff-line-number-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R682">682</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R683">683</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R684">684</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R685">685</a></span>
<span class="diff-line-number-hunk-header" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R686">...</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R687">687</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R688">688</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R689">689</a></span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre"> </span>
<span class="diff-line-number-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R690">690</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R691">691</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R692">692</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/91c65f833d6c66ec71675db5247acffd1784d30c#L0R693">693</a></span>
</pre>
</th>
<td class="diff-content" style="border: 1px solid #aaa">
<pre style="border: 0; font-family: Consolas, Menlo, "Liberation Mono", Courier, monospace; line-height: 1.2; margin: 0; padding: 0.5em; white-space: normal"><span class="diff-hunk-header" style="background-color: #eaf2f5; color: #999999; display: block; white-space: pre">@@ -673,6 +673,13 @@ <span class="diff-context" style="background-color: #ffffaa; color: #000000">int ha_mroonga::create(const char *name, TABLE *table, HA_CREATE_INFO *info)</span></span>
<span class="diff-not-changed" style="display: block; white-space: pre"> continue; // pkey is already handled</span>
<span class="diff-not-changed" style="display: block; white-space: pre"> }</span>
<span class="diff-not-changed" style="display: block; white-space: pre"> </span>
<span class="diff-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre">+ // disable secondary key</span>
<span class="diff-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre">+ if (i != pkeynr) {</span>
<span class="diff-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre">+ GRN_LOG(ctx, GRN_LOG_ERROR, "secondary key is not supported (%s)", db_path);</span>
<span class="diff-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre">+ grn_obj_remove(ctx, tbl_obj);</span>
<span class="diff-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre">+ DBUG_RETURN(-1);</span>
<span class="diff-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre">+ }</span>
<span class="diff-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre">+</span>
<span class="diff-not-changed" style="display: block; white-space: pre"> grn_obj *idx_tbl_obj, *idx_col_obj, *col_obj, *col_type, buf;</span>
<span class="diff-not-changed" style="display: block; white-space: pre"> KEY key_info = table->s->key_info[i];</span>
<span class="diff-not-changed" style="display: block; white-space: pre"> </span>
<span class="diff-hunk-header" style="background-color: #eaf2f5; color: #999999; display: block; white-space: pre">@@ -680,7 +687,7 @@ <span class="diff-context" style="background-color: #ffffaa; color: #000000">int ha_mroonga::create(const char *name, TABLE *table, HA_CREATE_INFO *info)</span></span>
<span class="diff-not-changed" style="display: block; white-space: pre"> int key_parts = key_info.key_parts;</span>
<span class="diff-not-changed" style="display: block; white-space: pre"> if (key_parts != 1) {</span>
<span class="diff-not-changed" style="display: block; white-space: pre"> GRN_LOG(ctx, GRN_LOG_ERROR, "complex key is not supported (%s)", db_path);</span>
<span class="diff-deleted" style="background-color: #ffaaaa; color: #000000; display: block; white-space: pre">- return -1;</span>
<span class="diff-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre">+ DBUG_RETURN(-1);</span>
<span class="diff-not-changed" style="display: block; white-space: pre"> }</span>
<span class="diff-not-changed" style="display: block; white-space: pre"> </span>
<span class="diff-not-changed" style="display: block; white-space: pre"> mrn_index_name_gen(tbl_name, i, idx_name);</span>
</pre>
</td>
</tr>
</tbody>
</table>
</div>
</body>
</html>