Name Of The Folder Holding Temporary Files

SQLITE_EXTERN char *sqlite3_temp_directory;

If this global variable is made to point to a string which is
the name of a folder (a.k.a. directory), then all temporary files
created by SQLite when using a built-in VFS
will be placed in that directory. If this variable
is a NULL pointer, then SQLite performs a search for an appropriate
temporary file directory.

Applications are strongly discouraged from using this global variable.
It is required to set a temporary folder on Windows Runtime (WinRT).
But for all other platforms, it is highly recommended that applications
neither read nor write this variable. This global variable is a relic
that exists for backwards compatibility of legacy applications and should
be avoided in new projects.

It is not safe to read or modify this variable in more than one
thread at a time. It is not safe to read or modify this variable
if a database connection is being used at the same time in a separate
thread.
It is intended that this variable be set once
as part of process initialization and before any SQLite interface
routines have been called and that this variable remain unchanged
thereafter.

Note to Windows Runtime users: The temporary directory must be set
prior to calling sqlite3_open or sqlite3_open_v2. Otherwise, various
features that require the use of temporary files may fail. Here is an
example of how to do this using C++ with the Windows Runtime: