{"id":13508822,"url":"https://github.com/mmzeeman/esqlite","last_synced_at":"2025-04-12T21:26:26.487Z","repository":{"id":1743065,"uuid":"2568810","full_name":"mmzeeman/esqlite","owner":"mmzeeman","description":"Erlang NIF for sqlite","archived":false,"fork":false,"pushed_at":"2024-05-22T15:54:29.000Z","size":10000,"stargazers_count":123,"open_issues_count":5,"forks_count":76,"subscribers_count":8,"default_branch":"master","last_synced_at":"2024-05-22T16:42:57.844Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mmzeeman.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":"AUTHORS","dei":null,"publiccode":null,"codemeta":null}},"created_at":"2011-10-13T11:18:58.000Z","updated_at":"2024-06-18T15:31:46.279Z","dependencies_parsed_at":"2024-06-18T15:31:45.232Z","dependency_job_id":"afa9a278-356b-4c28-96e9-f093ba9edff3","html_url":"https://github.com/mmzeeman/esqlite","commit_stats":{"total_commits":269,"total_committers":17,"mean_commits":"15.823529411764707","dds":"0.27137546468401486","last_synced_commit":"18b6da89e3902efab2d9fe886cafa3a20ed47c7f"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mmzeeman%2Fesqlite","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mmzeeman%2Fesqlite/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mmzeeman%2Fesqlite/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mmzeeman%2Fesqlite/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mmzeeman","download_url":"https://codeload.github.com/mmzeeman/esqlite/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248633486,"owners_count":21136877,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-01T02:00:59.020Z","updated_at":"2025-04-12T21:26:26.431Z","avatar_url":"https://github.com/mmzeeman.png","language":"C","funding_links":[],"categories":["ORM and Datamapping"],"sub_categories":[],"readme":"Esqlite ![Test](https://github.com/mmzeeman/esqlite/workflows/Test/badge.svg)\n=======\n\nAn Erlang nif library for sqlite3.\n\nIntroduction\n------------\n\nThis library allows you to use the excellent sqlite engine from\nerlang. The library is implemented as a nif library, which allows for\nthe fastest access to a sqlite database. This can be risky, as a bug\nin the nif library or the sqlite database can crash the entire Erlang\nVM. If you do not want to take this risk, it is always possible to\naccess the sqlite nif from a separate erlang node.\n\nSpecial care has been taken not to block the normal erlang scheduler\nof the calling process. This is done by handling neccesary commands\nfrom erlang by using a dirty scheduler.\n\nSQLite Compile Options\n----------------------\n\nEsqlite contains an embedded version of sqlite3. Currently version\n`3.45.2` is embedded in the repositoy. It is also possible to use \nsqlite provided by the system by using the `ESQLITE_USE_SYSTEM` \nenvironment flag. \n\nWhen sqlite is compiled, the following compile flags are used. These\nflags are recommended by sqlite.\n\n```\nSQLITE_DQS=0 SQLITE_THREADSAFE=1 SQLITE_DEFAULT_MEMSTATUS=0\nSQLITE_DEFAULT_WAL_SYNCHRONOUS=1 SQLITE_LIKE_DOESNT_MATCH_BLOBS\nSQLITE_MAX_EXPR_DEPTH=0 SQLITE_OMIT_DEPRECATED\nSQLITE_OMIT_PROGRESS_CALLBACK SQLITE_USE_ALLOCA\nSQLITE_OMIT_AUTOINIT SQLITE_USE_URI\nSQLITE_ENABLE_FTS3 SQLITE_ENABLE_FTS3_PARENTHESIS\nSQLITE_ENABLE_FTS4\nSQLITE_ENABLE_FTS5\nSQLITE_ENABLE_MATH_FUNCTIONS\nSQLITE_ENABLE_JSON1\nSQLITE_ENABLE_RTREE\nSQLITE_ENABLE_GEOPOLY\n```\n\nThe use of flag `SQLITE_DQS=0` is new in version `0.7`. It can lead\nto incompatibilities with respect to the use of single and double \nqouted values. Historically sqlite didn't differentiate between double\nand single quoted values, but SQL does. In retrospect, the authors of \nsqlite, think this was a mistake, and introduced this compile flag \nto correct this mistake. It means that string literals **must** use \nsingle quotes:\n\n```\nINSERT INTO table VALUES('abcd', 1234);\n```\n\nWhen double quotes are used the value is seen as object values in \nSQL. So a query like:\n\n```\nINSERT INTO table VALUES(\"abcd\", 1234);\n```\n\nWill not work, because it sees the value 'abcd' as a SQL object\nvalue, and not a string literal.\n\nVersion 0.8.0\n-------------\n\nThis version is a major derivation from previous versions. When \nI started with this library it was implemented by using a separate\nos level thread per connection. At the time this was the only way\nto use functions in C which take longer to process than 1ms. \nA lot has changed since then. The VM now has dirty schedulers \nwhich make it possible to remove the thread per connection.\nThis makes it possible to open a lot more connections. On the\nSQLite side some things have also changed. Extended error codes,\nintrospection into the internals. This release modernizes the\nintegration. In some places the API is no longer compatible and\nwill require small changes. In order to ease this process the \nlibrary now has typespecs, and the documentation was extended.\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmmzeeman%2Fesqlite","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmmzeeman%2Fesqlite","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmmzeeman%2Fesqlite/lists"}