|
MySQL 5.6.14 Source Code Document
|


Public Member Functions | |
| Materialized_cursor (select_result *result, TABLE *table) | |
| int | send_result_set_metadata (THD *thd, List< Item > &send_result_set_metadata) |
| virtual bool | is_open () const |
| virtual int | open (JOIN *join __attribute__((unused))) |
| virtual void | fetch (ulong num_rows) |
| virtual void | close () |
Public Member Functions inherited from Server_side_cursor | |
| Server_side_cursor (MEM_ROOT *mem_root_arg, select_result *result_arg) | |
| virtual int | open (JOIN *top_level_join)=0 |
Additional Inherited Members | |
Static Public Member Functions inherited from Server_side_cursor | |
| static void | operator delete (void *ptr, size_t size) |
Protected Attributes inherited from Server_side_cursor | |
| select_result * | result |
Materialized_cursor – an insensitive materialized server-side cursor. The result set of this cursor is saved in a temporary table at open. The cursor itself is simply an interface for the handler of the temporary table.
Definition at line 34 of file sql_cursor.cc.
|
virtual |
Fetch up to the given number of rows from a materialized cursor.
Precondition: the cursor is open.
If the cursor points after the last row, the fetch will automatically close the cursor and not send any data (except the 'EOF' packet with SERVER_STATUS_LAST_ROW_SENT). This is an extra round trip and probably should be improved to return SERVER_STATUS_LAST_ROW_SENT along with the last row.
Implements Server_side_cursor.
Definition at line 318 of file sql_cursor.cc.

| int Materialized_cursor::send_result_set_metadata | ( | THD * | thd, |
| List< Item > & | send_result_set_metadata | ||
| ) |
Preserve the original metadata to be sent to the client. Initiate sending of the original metadata to the client (call Protocol::send_result_set_metadata()).
| thd | Thread identifier. |
| send_result_set_metadata | List of fields that would be sent. |
Definition at line 226 of file sql_cursor.cc.