duckweb_header

scalar · LOAD duckweb

duckweb_header(VARCHAR, VARCHAR) -> VARCHAR

One header line, for the extra block of a head or a redirect.

duckweb_head(200, 'text/html', duckweb_header('Cache-Control', 'no-store'))

Produces name: value\r\n. Concatenate several with || to build a block.

CR and LF are stripped from both halves. A value here can have come from user input by way of the app’s SQL, and a newline in it would otherwise let that input forge further headers or end the head early.