--- warning: DO NOT CHANGE THIS MANUALLY, THIS IS GENERATED BY https://github.com/duckdb/community-extensions repository, check README there title: mentat excerpt: | DuckDB Community Extensions Datomic-compatible Datalog query engine as a DuckDB extension extension: name: mentat description: Datomic-compatible Datalog query engine as a DuckDB extension version: 1.19.1 language: Rust build: cargo license: Apache-2.0 maintainers: - gburd requires_toolchains: "rust;python3" excluded_platforms: "wasm_mvp;wasm_eh;wasm_threads;windows_amd64_mingw;linux_amd64_musl" repo: github: gburd/mentat ref: c9ebe020f8ff5feb71c7792fc56669101b367868 variegata: c9ebe020f8ff5feb71c7792fc56669101b367868 docs: hello_world: | LOAD mentat; -- Transact a schema and data into the mentat store 'default'. Its datoms are -- DuckDB tables (schema `mentat`) in the database you have open. SELECT edn_t('default', '[{:db/ident :person/name :db/valueType :db.type/string :db/cardinality :db.cardinality/one}]'); SELECT edn_t('default', '[{:person/name "Alice"} {:person/name "Bob"}]'); -- Datalog: a table function, so the rows join against your own tables. SELECT * FROM edn_q('default', '[:find ?e ?name :where [?e :person/name ?name]]', '{}'); SELECT * FROM edn_q('default', '[:find ?e . :in ?name :where [?e :person/name ?name]]', '{"inputs": ["Alice"]}'); -- The datoms are plain DuckDB rows. SELECT count(*) FROM mentat.datoms; extended_description: | mentat is a Datomic-compatible database: an EDN/Datalog front-end over an entity-attribute-value store with history. This extension stores mentat's datoms in DuckDB: each mentat store is a schema of ordinary tables in the database the extension is loaded into, so the data persists with that database and plain SQL can read it. It exposes `edn_t` (transact), `edn_q` (Datalog query table function, with :in inputs and asOf/since), `edn_pull` (pull pattern -> JSON) and `edn_eval` (sandboxed mino script), so Datalog query results can be joined against native DuckDB tables. The same engine is also available as an embedded Rust library and CLI (on SQLite) and a PostgreSQL extension (`pg_mentat`). Source: https://codeberg.org/gregburd/mentat extension_star_count: 2 extension_star_count_pretty: 2 extension_download_count: 679 extension_download_count_pretty: 679 image: '/images/community_extensions/social_preview/preview_community_extension_mentat.png' layout: community_extension_doc --- ### Compatibility Matrix This table covers all DuckDB releases that have not reached [end-of-life](https://duckdb.org/release_calendar), including LTS releases, and shows the 2 most recent patch releases of each. Older patch releases are not listed, but the extension may be available for them as well.
| Platform | 1.4.4 | 1.4.5 | 1.5.5 | 1.5.6 | 2.0.0 | | :--- | :---: | :---: | :---: | :---: | :---: | | Linux AMD64 | ❌ | ❌ | ❌ | ✅ | ✅ | | Linux ARM64 | ❌ | ❌ | ❌ | ✅ | ✅ | | macOS AMD64 | ❌ | ❌ | ❌ | ✅ | ✅ | | macOS ARM64 | ❌ | ❌ | ❌ | ✅ | ✅ | | Windows AMD64 | ❌ | ❌ | ❌ | ✅ | ✅ | | Windows ARM64 | ❌ | ❌ | ❌ | ❌ | ❌ | | WebAssembly | ❌ | ❌ | ❌ | ❌ | ❌ | ### Installing and Loading ```sql INSTALL {{ page.extension.name }} FROM community; LOAD {{ page.extension.name }}; ``` {% if page.docs.hello_world %} ### Example ```sql {{ page.docs.hello_world }}``` {% endif %} {% if page.docs.extended_description %} ### About {{ page.extension.name }} {{ page.docs.extended_description }} {% endif %} ### Added Functions
| function_name | function_type | description | comment | examples | |---------------|---------------|-------------|---------|----------| | edn_eval | scalar | NULL | NULL | | | edn_pull | scalar | NULL | NULL | | | edn_q | table | NULL | NULL | | | edn_t | scalar | NULL | NULL | | | mentat_import | scalar | NULL | NULL | | ### Overloaded Functions
This extension does not add any function overloads. ### Added Types
This extension does not add any types. ### Added Settings
| name | description | input_type | scope | aliases | typed_value | |----------------|---------------------------------------------------------|------------|--------|---------|-------------| | temp_directory | Set the directory to which temporary files are written. | VARCHAR | GLOBAL | [] | post.db.tmp |