MONGOC_CLIENT...X_QUERY_LENGTH(3)

πŸ“¦
version 2.5.6 Β· 2 versions
, in epel 10

πŸ’… MONGOC_CLIENT...X_QUERY_LENGTH(3) πŸ’…

okay so bestie, this is a page from libmongoc β€” yes, the MongoDB C driver β€” and the function name is genuinely a whole paragraph, i'm not even joking. it's mongoc_client_encryption_encrypt_string_substring_opts_set_str_max_query_length, which is giving "my parents named me after the entire family tree" energy 😭. anyway. let's get into it.


✨ SYNOPSIS ✨

void
mongoc_client_encryption_encrypt_string_substring_opts_set_str_max_query_length(
   mongoc_client_encryption_encrypt_string_substring_opts_t *opts,
   int32_t str_max_query_length);

like, look at it. iconic. unhinged. both. πŸŽ€

Changed in version 2.4.0: this got renamed from the now-deprecated text API. so if you're out here still using the old name, bestie… it's deprecated. it's giving legacy. move on πŸ’€

this function sets the maximum query length for substring string search encryption options. that's the whole job. she's a setter. she sets. periodt. πŸ‘‘


🌸 PARAMETERS 🌸

  • opts β€” a mongoc_client_encryption_encrypt_string_substring_opts_t. that's the options struct you're poking at. yes, the type name is also a marathon. we don't talk about it. 🫢
  • str_max_query_length β€” the maximum query length for substring search. must be greater than zero. like, actually. zero is not it. negative is definitely not it. keep it > 0 or don't come to the function at all, iykyk. ⭐
⚠️ HEADS UP, THIS PART IS IMPORTANT ⚠️ the "substringPreview" query type is in preview and should be used for experimental workloads only. this feature is unstable and its security is not guaranteed until it's released as Generally Available (GA). and the plot twist? the GA version of this feature may not be backwards compatible with the preview version. so like… build on it at your own risk, babes. no cap. πŸ™ˆ

πŸ¦‹ SEE ALSO πŸ¦‹

  • mongoc_client_encryption_encrypt_string_substring_opts_new()
  • mongoc_client_encryption_encrypt_string_opts_set_substring()

go read those too, they're the supporting cast and they ate πŸ’…


🧚 AUTHOR 🧚

MongoDB, Inc β€” the masterminds behind all of this ✨


2009-present, MongoDB, Inc. β€” she's been booked and busy since 2009, we love a long-running gig 🌈


and that's the page, bestie!! mwah πŸ’– this lil doc is from libmongoc version 2.5.6, dated Oct 09, 2026 β€” screenshot it, cite it, live by it πŸŽ€βœ¨

πŸ“¦ where this page comes from