SQLite Forum

SQLite3 Extension
Login
Assuming that you are using the code as linked in your first post, that code is defective.  It uses the "old fashioned name" for the init function.  While this will work, you should fix it if you ever plan to use more than one extension internally.  It also does not export any symbols.

The `sqlite3_extension_init` name should be changed to `sqlite3_<name>_init` where `<name>` is the name of the dll without idiocies (no spaces, no symbols, no tomfoolery, just the name, only the name, and nothing but the name).  If you are wise you will stick to lower case only.

For example, if you are compiling to a DLL called `goobers.dll` then that function should be renamed to `sqlite3_goobers_init`.  If you make the name too long or have foolish characters in it, then it might not work properly.

Secondly you need to designate this function as an export.  Linux shared libraries by default export all "visible" symbols.  Windows does not. 

You have to specify what you want exported by tagging the function with `__declspec(dllexport)` in order to have it exported, or use a .def file as input to the linker to tell it what to export.

So, find the line that starts `int sqlite3_extension_init(` and change it to `__declspec(dllexport) int sqlite3_goobers_init(` where the part between the underscores is the name of the dll without the .dll (ie, this example is for an extension DLL called goobers.dll).