/memgraph:memgraph-database-configurationfrom memgraph
Configures Memgraph triggers, transactions, storage modes, data durability, and memory settings. Covers trigger syntax, transaction isolation levels, and runtime configuration.
Ships in memgraph. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
CREATE TRIGGER name
[SECURITY DEFINER|INVOKER]
[ON [() | -->] CREATE|UPDATE|DELETE]
[BEFORE|AFTER COMMIT]
EXECUTE <cypher statements>
Default security: DEFINER. Triggers are persisted to disk.
| Event | Available variables |
|---|---|
ON () CREATE | createdVertices |
ON --> CREATE | createdEdges |
ON CREATE | createdVertices, createdEdges, createdObjects |
ON () UPDATE | setVertexProperties, removedVertexProperties, setVertexLabels, removedVertexLabels, updatedVertices |
ON --> UPDATE | setEdgeProperties, removedEdgeProperties, updatedEdges |
ON UPDATE | All update vars + updatedObjects |
ON () DELETE | deletedVertices |
ON --> DELETE | deletedEdges |
ON DELETE | deletedVertices, deletedEdges, deletedObjects |
| No event | All variables available |
Auto-set creation timestamp:
CREATE TRIGGER setCreatedAt
ON () CREATE AFTER COMMIT EXECUTE
UNWIND createdVertices AS v SET v.created_at = timestamp();
Auto-set updated_at:
CREATE TRIGGER setUpdatedAt
ON UPDATE AFTER COMMIT EXECUTE
UNWIND updatedObjects AS obj
WITH CASE
WHEN obj.vertex IS NOT null THEN obj.vertex
WHEN obj.edge IS NOT null THEN obj.edge
END AS entity
SET entity.updated_at = timestamp();
Dynamic PageRank via trigger:
CREATE TRIGGER pagerankTrigger
BEFORE COMMIT EXECUTE
CALL pagerank_online.update(createdVertices, createdEdges, deletedVertices, deletedEdges)
YIELD node, rank SET node.rank = rank;
DROP TRIGGER name;
SHOW TRIGGERS;
BEGIN;
MATCH (n:Account {id: 1}) SET n.balance = n.balance - 100;
MATCH (n:Account {id: 2}) SET n.balance = n.balance + 100;
COMMIT;
ROLLBACK; to discard. If any query fails, the transaction cannot be committed.
SHOW TRANSACTIONS;
SHOW RUNNING TRANSACTIONS;
TERMINATE TRANSACTIONS "tid1", "tid2";
Requires TRANSACTION_MANAGEMENT privilege to see/terminate other users' transactions.
SET GLOBAL TRANSACTION ISOLATION LEVEL SNAPSHOT ISOLATION;
SET SESSION TRANSACTION ISOLATION LEVEL READ COMMITTED;
SET NEXT TRANSACTION ISOLATION LEVEL READ UNCOMMITTED;
SHOW STORAGE INFO ON CURRENT DATABASE;
To check the level in use, read storage_isolation_level from SHOW STORAGE INFO ON CURRENT DATABASE.
The unscoped SHOW STORAGE INFO reports global_isolation_level, which is the start-up default
(--isolation-level) and doesn't change after SET GLOBAL TRANSACTION ISOLATION LEVEL.
| Level | Default | Protects against |
|---|---|---|
SNAPSHOT ISOLATION | Yes (IN_MEMORY_TRANSACTIONAL) | Dirty read, non-repeatable read, phantom |
READ COMMITTED | Dirty read | |
READ UNCOMMITTED | Nothing (read-only access) |
IN_MEMORY_ANALYTICAL has no isolation levels.
ON_DISK_TRANSACTIONAL supports only SNAPSHOT ISOLATION.
| Type | Notes |
|---|---|
Null | Same as property absent |
String | |
Boolean | |
Integer | |
Float | Resolution via --storage-floating-point-resolution-bits |
List | Homogeneous for storage as node property |
Map | Must replace entirely |
Duration | duration("P2DT3H") |
Date | date("2024-01-15") |
LocalTime | localTime("14:30:00") |
LocalDateTime | localDateTime("2024-01-15T14:30:00") |
ZonedDateTime | datetime("2024-01-15T14:30:00Z") |
Enum | Must be defined first (see memgraph-indexes-and-constraints) |
Point | 2D/3D, Cartesian or WGS-84 |
Lists and Maps cannot be mutated element-by-element - replace the whole value.
Duration +/- Duration = Duration. Date +/- Duration = Date. Date - Date = Duration. Same for LocalTime, LocalDateTime, ZonedDateTime.
| Type | SRID | Constructor |
|---|---|---|
| WGS-84 2D | 4326 | point({longitude: -73.93, latitude: 40.73}) |
| WGS-84 3D | 4979 | point({longitude: -73.93, latitude: 40.73, height: 10}) |
| Cartesian 2D | 7203 | point({x: 0, y: 1}) |
| Cartesian 3D | 9157 | point({x: 0, y: 1, z: 2}) |
STORAGE MODE IN_MEMORY_TRANSACTIONAL;
STORAGE MODE IN_MEMORY_ANALYTICAL;
STORAGE MODE ON_DISK_TRANSACTIONAL;
SHOW STORAGE INFO ON CURRENT DATABASE;
To check the mode in use, read storage_mode from SHOW STORAGE INFO ON CURRENT DATABASE.
The unscoped SHOW STORAGE INFO reports global_storage_mode, which is the start-up default
(--storage-mode) and doesn't change after STORAGE MODE ....
| Mode | ACID | WAL | Periodic snapshots | Use case |
|---|---|---|---|---|
IN_MEMORY_TRANSACTIONAL | Full | Yes | Yes | Default - concurrent reads/writes |
IN_MEMORY_ANALYTICAL | No | No | Manual only | Bulk import, analytics (up to 6x faster) |
ON_DISK_TRANSACTIONAL | Snapshot isolation | RocksDB | - | Experimental, larger-than-memory |
Cannot switch in-memory to on-disk with data present. Cannot switch with active transactions.
CREATE SNAPSHOT;
SHOW SNAPSHOTS;
Periodic interval (runtime):
SET DATABASE SETTING "storage.snapshot.interval" TO "1200";
SET DATABASE SETTING "storage.snapshot.interval" TO "* * 12 * * *";
Flags: --storage-snapshot-interval, --storage-snapshot-on-exit,
--storage-parallel-snapshot-creation.
Enabled by default (--storage-wal-enabled). Cannot use WAL without snapshots.
Older WAL files are deleted after each snapshot.
LOCK DATA DIRECTORY;
UNLOCK DATA DIRECTORY;
DATA DIRECTORY LOCK STATUS;
MATCH (n) RETURN n QUERY MEMORY LIMIT 50 MB;
CALL proc() PROCEDURE MEMORY LIMIT 100 MB YIELD *;
FREE MEMORY;
SHOW STORAGE INFO;
Instance limit: --memory-limit (MiB). Property compression:
--storage-property-store-compression-enabled.
RAM ≈ nodes × 204B + edges × 154B + properties + indexes
For 50+ indexes add ~20% overhead.
IN_MEMORY_ANALYTICAL has no isolation levels or ACID guaranteesIN_MEMORY_TRANSACTIONAL (see memgraph-indexes-and-constraints)What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
memgraph, graph-database, triggers, transactions, database-configuration
memgraph@memgraph is listed by memgraph/marketplace — review the source before installing
npx claudepluginhub memgraph/marketplace --plugin memgraph14 skills in this plugin
/memgraph-brand-uiGenerate apps, demos, dashboards, diagrams, landing pages, and any visual output that looks like it belongs in the Memgraph product family. Use whenever producing UI, visual artifacts (Mermaid, SVGs, charts), Lab-style admin tools, internal dashboards, feature splash pages, or embeddable widgets for Memgraph engineers./memgraph-cpp-query-modulesDevelop custom query modules in C++ for Memgraph graph database. Use when creating high-performance graph algorithms, procedures (ProcedureType::Read/Write), or functions using the mgp.hpp C++ API. Covers compilation, memory management, graph traversal, and module deployment./memgraph-cypher-syntaxWrite Cypher queries for Memgraph, including Memgraph-specific extensions like deep path traversals (BFS, DFS, WSP, ASP, KSP with filter/weight lambdas), text and vector search, parallel execution, and CALL subqueries. Use when the user asks to write, fix, or optimize a Cypher query for Memgraph, or asks about Cypher syntax differences between Memgraph and Neo4j./memgraph-graph-ragLanguage-agnostic blueprint for building GraphRAG systems with Memgraph and agent tooling. Covers end-to-end architecture, schema design, ingestion, hybrid retrieval, tool contracts, and evaluation. Use when designing GraphRAG platforms that must work across multiple programming languages./memgraph-import-dataImport or migrate data into Memgraph from CSV, Parquet, JSON/JSONL, CYPHERL dumps, relational databases (PostgreSQL, MySQL, SQL Server, Oracle, DuckDB) or Neo4j: choosing between LOAD CSV, cross_database procedures and client-driven batches, preparing indexes and storage mode, ordering nodes before relationships, and verifying counts. Use when the user wants to load, bulk-insert, ingest or migrate data into Memgraph, or an import is slow or failing./memgraph-indexes-and-constraintsCreate and manage Memgraph indexes, constraints, and enums. Use when the user asks about indexing strategy, creating or dropping indexes, schema enforcement, uniqueness or existence constraints, data type constraints, enums, or ANALYZE GRAPH.Other plugins' skills for the same job