SPI_FREEPLAN(3)

πŸ“¦ version 16.15, in opensuse-leap 16.0

πŸ’– SPI_FREEPLAN(3) πŸ’–

okay bestie, so you know SPI_freeplan from the PostgreSQL 16.15 documentation? yeah. she's the cleanup queen and we're gonna talk about her. πŸŽ€


✨ NAME ✨

SPI_freeplan β€” frees a prepared statement you saved earlier, no cap πŸ§ΉπŸ’…

✨ SYNOPSIS ✨

int SPI_freeplan(SPIPlanPtr plan)

✨ DESCRIPTION ✨

So SPI_freeplan releases a prepared statement β€” one that was previously returned by SPI_prepare, or saved by SPI_keepplan or SPI_saveplan. that's literally it, that's the whole gig. she takes your saved statement and lets it go. closure. growth. main character energy. πŸ¦‹

✨ ARGUMENTS ✨

  • SPIPlanPtr plan β€” pointer to the statement you wanna free. give her the one you want gone, bestie 🌸

✨ RETURN VALUE ✨

  • 0 on success β€” slay, it worked πŸŽ‰
  • SPI_ERROR_ARGUMENT if plan is NULL or invalid β€” like, she's not mad, she's just disappointed 😭

πŸ’€ real talk: if your plan is NULL or invalid, you're getting SPI_ERROR_ARGUMENT back, periodt. no silent success, no vibes.

okay and that's the whole page, bestie β€” short and iconic, just like her πŸ‘‘. this was from the PostgreSQL 16.15 docs, dated 2026, and honestly? she ate. πŸŒˆπŸ’œ

πŸ“¦ where this page comes from