---
name: "mysql_stmt_fetch_column"
section: "3"
platform: "linux"
package: "mariadb"
version: "13.0.2-2"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/mysql_stmt_fetch_column"
---

# mysql\_stmt\_fetch\_column(3)

### Name

mysql\_stmt\_fetch\_column - Fetches a single column into bind buffer

### Synopsis

-

  ```
  #include <mysql.h>
  int mysql_stmt_fetch_column(MYSQL_STMT * stmt,
                              MYSQL_BIND * bind_arg,
                              unsigned int column,
                              unsigned long offset);
  ```

### Description

This function can be used to fetch large data of a single column in pieces.

### Parameter

- •

  `stmt` - a statement handle, which was previously allocated by **[mysql\_stmt\_init(3)](/mysql_stmt_init/3.md)**.

- •

  `bind_arg` - a pointer to a MYSQL\_BIND structure.

- •

  `column` - number of column, first column is numbered zero.

- •

  `offset` - offset at which to begin retrieving data.

### Return value

Returns zero on success, non-zero on failure.

### Notes

- •

  The size of the buffer is specified within MYSQL\_BIND structure.

### See Also

- •

  **[mysql\_stmt\_fetch(3)](/mysql_stmt_fetch/3.md)**

- •

  **[mysql\_stmt\_send\_long\_data(3)](/mysql_stmt_send_long_data/3.md)**
