Get Absolute DB running in under 60 seconds. Run your first SQL query, insert a vector, and connect from Python, Node.js, or psql.
The quickest way to get Absolute DB is the one-line installer. It detects your platform (Linux x86-64, Linux ARM64, macOS Intel, macOS Apple Silicon), installs build tools, compiles from source, runs all 2,737 tests, and sets up a systemd service.
curl -fsSL https://downloads.absolutedb.com/install.sh | bash
Script source: downloads.absolutedb.com/install.sh — checksum: install.sh.sha256
curl -fsSL https://downloads.absolutedb.com/install.sh -o /tmp/absdb-install.sh
curl -fsSL https://downloads.absolutedb.com/install.sh.sha256 \
| sed 's|install.sh|/tmp/absdb-install.sh|' \
| sha256sum -c
# Expected: /tmp/absdb-install.sh: OK
bash /tmp/absdb-install.sh
After installation the server starts automatically. Binaries are in /usr/local/bin and config in /etc/absdb/absdb.conf.
curl http://localhost:8080/health
# {"healthy":true,"version":"","status":"running"}
Prefer Homebrew on macOS?
brew tap absolutedb/tap
brew install absdb
# Start as a service
brew services start absdb
Or run the official Docker image:
docker pull absolutedb/absdb:latest
docker run -d \
--name absdb \
-p 5433:5433 \
-p 8080:8080 \
-v absdb-data:/var/lib/absdb \
absolutedb/absdb:latest
Once the server is running, open the built-in interactive CLI:
absdb --host localhost --port 5433 --db mydb
At the absdb> prompt, create a table and insert some rows:
-- Create a table
CREATE TABLE products (
id SERIAL PRIMARY KEY,
name TEXT NOT NULL,
price NUMERIC(10,2),
in_stock BOOLEAN DEFAULT true
);
-- Insert rows
INSERT INTO products (name, price) VALUES
('Widget Pro', 29.99),
('Gadget Max', 149.99),
('Nano Sensor', 9.99);
-- Query
SELECT id, name, price
FROM products
WHERE price < 100
ORDER BY price DESC;
-- Result:
-- id | name | price
-- ----+-------------+-------
-- 1 | Widget Pro | 29.99
-- 3 | Nano Sensor | 9.99
Absolute DB stores and searches high-dimensional vectors natively. Create a table with a vector column, build an HNSW index, and run a similarity search — all in SQL.
-- Create a table with a vector column (384 dimensions)
CREATE TABLE documents (
id SERIAL PRIMARY KEY,
title TEXT,
body TEXT,
embedding VECTOR(384)
);
-- Create an HNSW index for fast approximate nearest-neighbour search
CREATE INDEX idx_docs_embedding
ON documents USING HNSW (embedding)
WITH (metric = 'cosine');
-- Insert rows (in practice, embeddings come from EMBED() or your model)
INSERT INTO documents (title, body, embedding) VALUES
('Raft Consensus', 'Raft is a consensus algorithm...', EMBED('minilm', 'Raft consensus algorithm')),
('MVCC Explained', 'Multi-version concurrency control...', EMBED('minilm', 'MVCC transactions')),
('Vector Search', 'HNSW enables fast ANN search...', EMBED('minilm', 'vector similarity search'));
-- Search for the top-3 most similar documents
SELECT id, title, embedding <=> EMBED('minilm', 'distributed consensus') AS distance
FROM documents
ORDER BY distance
LIMIT 3;
-- Hybrid BM25 + vector search (RRF fusion)
SELECT id, title
FROM documents
WHERE body MATCH 'consensus'
ORDER BY embedding <=> EMBED('minilm', 'leader election')
LIMIT 5;
Absolute DB speaks PostgreSQL wire protocol v3. Any tool that works with PostgreSQL works with Absolute DB — including psql, pgAdmin, DBeaver, and Beekeeper Studio.
# Default port is 5433; use -p 5432 if you configured that
psql -h localhost -p 5433 -U absdb -d mydb
# With a connection string
psql "postgresql://absdb:password@localhost:5433/mydb"
# Once connected, try some queries
mydb=# SELECT version();
mydb=# \dt -- list tables
mydb=# \d products -- describe a table
You can also point pgAdmin or DBeaver at localhost:5433 using the PostgreSQL driver — no special configuration needed.
Use the standard psycopg2 library or any other PostgreSQL-compatible Python driver. No special Absolute DB driver required.
pip install psycopg2-binary
import psycopg2
conn = psycopg2.connect(
host="localhost",
port=5433,
dbname="mydb",
user="absdb",
password="password"
)
cur = conn.cursor()
# Create and populate a table
cur.execute("""
CREATE TABLE IF NOT EXISTS users (
id SERIAL PRIMARY KEY,
name TEXT NOT NULL,
email TEXT UNIQUE NOT NULL
)
""")
cur.execute(
"INSERT INTO users (name, email) VALUES (%s, %s) RETURNING id",
("Alice", "alice@example.com")
)
new_id = cur.fetchone()[0]
print(f"Inserted user with id={new_id}")
conn.commit()
# Query
cur.execute("SELECT id, name, email FROM users WHERE id = %s", (new_id,))
row = cur.fetchone()
print(row)
cur.close()
conn.close()
For async Python, use asyncpg or psycopg3 in async mode — both are fully compatible.
import asyncio, asyncpg
async def main():
conn = await asyncpg.connect(
"postgresql://absdb:password@localhost:5433/mydb"
)
rows = await conn.fetch("SELECT id, name FROM users LIMIT 10")
for row in rows:
print(dict(row))
await conn.close()
asyncio.run(main())
Use the pg package (node-postgres) — the most widely used PostgreSQL client for Node.js. Prisma, Drizzle, Sequelize, and TypeORM all work via the same underlying driver.
npm install pg
const { Pool } = require('pg');
const pool = new Pool({
host: 'localhost',
port: 5433,
database: 'mydb',
user: 'absdb',
password: 'password',
});
async function main() {
const client = await pool.connect();
try {
// Create table
await client.query(`
CREATE TABLE IF NOT EXISTS events (
id BIGSERIAL PRIMARY KEY,
type TEXT NOT NULL,
payload JSONB,
created_at TIMESTAMPTZ DEFAULT now()
)
`);
// Insert
const res = await client.query(
'INSERT INTO events (type, payload) VALUES ($1, $2) RETURNING id',
['page_view', { url: '/home', user_id: 42 }]
);
console.log('Inserted event id:', res.rows[0].id);
// Query
const { rows } = await client.query(
'SELECT id, type, payload FROM events ORDER BY created_at DESC LIMIT 5'
);
console.log(rows);
} finally {
client.release();
}
await pool.end();
}
main().catch(console.error);
Using Prisma? Set your DATABASE_URL in .env:
DATABASE_URL="postgresql://absdb:password@localhost:5433/mydb?schema=public"
Then use provider = "postgresql" in your schema.prisma. No additional configuration required.
Absolute DB supports the full SQL:2023 standard. Here are the fundamental CRUD patterns.
-- CREATE
CREATE TABLE orders (
id BIGSERIAL PRIMARY KEY,
customer_id INTEGER NOT NULL,
status TEXT NOT NULL DEFAULT 'pending',
total NUMERIC(12,2),
created_at TIMESTAMPTZ DEFAULT now(),
metadata JSONB
);
-- INSERT with RETURNING
INSERT INTO orders (customer_id, total, metadata)
VALUES (42, 199.99, '{"source": "web", "coupon": "SAVE10"}')
RETURNING id, created_at;
-- SELECT with JSON access
SELECT id, customer_id, total,
metadata->>'source' AS source
FROM orders
WHERE status = 'pending'
AND total > 100
ORDER BY created_at DESC
LIMIT 20;
-- UPDATE with RETURNING
UPDATE orders
SET status = 'shipped'
WHERE id = 1
RETURNING id, status;
-- UPSERT (INSERT ... ON CONFLICT)
INSERT INTO orders (id, customer_id, total)
VALUES (1, 42, 249.99)
ON CONFLICT (id) DO UPDATE
SET total = EXCLUDED.total;
-- DELETE
DELETE FROM orders
WHERE status = 'cancelled'
AND created_at < now() - INTERVAL '30 days';
-- Transaction with savepoint
BEGIN;
INSERT INTO orders (customer_id, total) VALUES (7, 50.00);
SAVEPOINT before_update;
UPDATE orders SET status = 'processing' WHERE customer_id = 7;
-- oops, rollback just the update
ROLLBACK TO SAVEPOINT before_update;
COMMIT;
| Operation | Latency (direct API) | Throughput |
|---|---|---|
| Point query (PK lookup) | 0.14 µs | 7M+ queries/sec |
| INSERT (batch, direct API) | — | 704K–736K rows/sec |
| INSERT (SQL path) | — | 330K–380K rows/sec |
| Prepared statement execute | ~2 µs | 500K+ queries/sec |
You're up and running. Here are the most useful next resources:
~154 KB binary · zero external dependencies · 2,737 tests passing · SQL:2023 100%