Is there any reliable and portable method of copying a prepared statement in SQLite3? Would the overhead from multiple copies be greater than just recompiling the statement?
Context: I need to copy a prepared statement from the main thread to many worker threads. The exact same statement is used by all of them, but they need to each have their own copy due to bound values and such not being thread safe.