summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorheikki@hundin.mysql.fi <>2004-03-17 22:28:49 +0200
committerheikki@hundin.mysql.fi <>2004-03-17 22:28:49 +0200
commit43706715daf1039a772c2d2aaceae0ef93ffe037 (patch)
treee3e1381d0b001805557dbdfcd9239d772128cd0c
parent24baf74c159474a3398059ac7f1e4c60254304ab (diff)
downloadmariadb-git-43706715daf1039a772c2d2aaceae0ef93ffe037.tar.gz
ha_innodb.cc:
Add a comment that InnoDB always retrieves the row id, if the clustered index was internally generated by InnoDB. Then we know the 'ref' to the row.
-rw-r--r--sql/ha_innodb.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/sql/ha_innodb.cc b/sql/ha_innodb.cc
index 8e190904e05..6edbc195a34 100644
--- a/sql/ha_innodb.cc
+++ b/sql/ha_innodb.cc
@@ -1983,7 +1983,11 @@ build_template(
}
} else if (prebuilt->hint_need_to_fetch_extra_cols
== ROW_RETRIEVE_PRIMARY_KEY) {
- /* We must at least fetch all primary key cols */
+ /* We must at least fetch all primary key cols. Note that if
+ the clustered index was internally generated by InnoDB on the
+ row id (no primary key was defined), then
+ row_search_for_mysql() will always retrieve the row id to a
+ special buffer in the prebuilt struct. */
fetch_primary_key_cols = TRUE;
}