mariadb_dyncol_unpack(3)
π mariadb_dyncol_unpack(3) π
okay so bestie, welcome to the MariaDB Connector/C manual, section 3, and today's main character is mariadb_dyncol_unpack β¨ it's the one that unpacks ALL the keys and values out of a dynamic column. literally the whole vibe. no cap.
β¨ Name β¨
mariadb_dyncol_unpack β extracts keys and values of all columns π
πΈ Synopsis πΈ
#include <mariadb_dyncol.h>
enum enum_dyncol_func_result
mariadb_dyncol_unpack(DYNAMIC_COLUMN *str,
uint *column_count,
MYSQL_LEX_STRING **column_keys,
DYNAMIC_COLUMN_VALUE **values);
π¦ Description π¦
The mariadb_dyncol_unpack() function extracts all keys and values of a dynamic column. like, every single one. it's giving "dump the whole thing out into your hands" energy and honestly? we love that for you π
π Parameter π
strβ Pointer to aDYNAMIC_COLUMNstructure. this is the dynamic column you're unpacking, the source of all the drama.- column count β Pointer to an unsigned integer which will receive the number of columns. so it hands you back the count, in a
uint *. (the synopsis calls this onecolumn_count, iykyk) column_keysβ Pointer of an array ofMYSQL_LEX_STRINGstructures, which will contain the column keys. the names go here π·οΈvaluesβ Pointer of an array ofDYNAMIC_COLUMN_VALUEstructures, which will contain the values. and the actual data goes here π
β Return value β
Returns ER_DYNCOL_OK on success, otherwise an error. that's it, that's the check. if it's not ER_DYNCOL_OK, something went sideways and you gotta deal with it π
π₯ Notes π₯
- The
column_keysandvaluesarrays will be allocated bymariadb_dyncol_unpack()and must be freed by application. π read that again bestie. you free them. it is NOT going to clean up after itself, and it's NOT your mom. memory leak incoming if you forget π
π See also π
mariadb_dyncol_get(3)mariadb_dyncol_list(3)
Version 3.4 of the MariaDB Connector/C docs, and yes the page is literally named mariadb_dyncol_unpack(3) β okay that's the whole thing, go unpack something and free your arrays, ily, mwah ππ«Άπ§
π¦ where this page comes from
- alpine 3.22: mariadb-doc 11.4.13-r0 Β· GPL-2.0-or-later
- alpine 3.23: mariadb-doc 11.4.13-r0 Β· GPL-2.0-or-later
- alpine 3.24: mariadb-doc 11.8.9-r0 Β· GPL-2.0-only
- arch rolling: mariadb 13.0.2-2 Β· GPL-2.0-only
- arch rolling: mariadb-lts 12.3.3-2 Β· GPL-2.0-only
- centos-stream 10: mariadb-connector-c-doc 3.4.4-2.el10 Β· LGPL-2.1-or-later
- debian trixie: libmariadb-dev 1:11.8.6-0+deb13u1 Β· GPL-2.0-only
- fedora 43: mariadb-connector-c-doc 3.4.5-2.fc43 Β· LGPL-2.1-or-later AND PHP-3.0 AND PHP-3.01
- fedora 43: mariadb-connector-c-doc 3.4.9-2.fc43 Β· LGPL-2.1-or-later AND PHP-3.0 AND PHP-3.01 AND LicenseRef-Fedora-Public-Domain
- fedora 44: mariadb-connector-c-doc 3.4.8-3.fc44 Β· LGPL-2.1-or-later AND PHP-3.0 AND PHP-3.01
- fedora 44: mariadb-connector-c-doc 3.4.9-2.fc44 Β· LGPL-2.1-or-later AND PHP-3.0 AND PHP-3.01 AND LicenseRef-Fedora-Public-Domain
- nixpkgs unstable: mariadb-server 11.8.8
- opensuse-leap 16.0: libmariadb-devel 3.4.9-160000.1.1 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: libmariadb-devel 3.4.9-160000.1.1 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: libmariadb-devel 3.4.9-160000.1.1 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: libmariadb-devel 3.4.9-160000.1.1 Β· LGPL-2.1-or-later
- ubuntu questing: libmariadb-dev 1:11.8.3-1build1
- ubuntu resolute: libmariadb-dev 1:11.8.6-5 Β· GPL-2.0-only
- ubuntu resolute: libmariadb-dev 1:11.8.6-5ubuntu0.1 Β· GPL-2.0-only
- ubuntu stonking: libmariadb-dev 1:11.8.9+ds-4ubuntu2 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms