Pinned Tweet
Layerbase isn't just databases anymore
Introducing Workspaces
pre-configured cloud VMs for your coding agents
- pick a size
- connect your agent subs or keys
- link repos
- open it in the IDE, terminal, or browser
claude, codex & more
opencode w/o sub
layerbase.link/x-ws-launch
documentdb does vector search from mongosh
db.runCommand({createIndexes:"docs",indexes:[{name:"v",key:{emb:"cosmosSearch"},cosmosSearchOptions:{kind:"vector-hnsw",similarity:"COS",dimensions:1536}}]})
then query with $vectorSearch. pgvector underneath
layerbase.com/db/documentdb
In honor of adding 2 new engines this week:
- DuckDB v2
- DocumentDB v1
we're giving away 3 months at 99% off of Solo and Pro plans
3 coupons available
first come first serve, good Luck
99PCTOFFX3
layerbase.com
DocumentDB is now on Layerbase
(with branching)
layerbase.com/blog/documentd…
changing a column in sqlite means rebuilding the table. libsql just alters it
ALTER TABLE users
ALTER COLUMN email TO email TEXT NOT NULL;
catch is it only applies to new or updated rows. old rows aren't rewritten or rechecked, so clean up existing NULLs first
Railway paused builds two days in a row. Can you move your app without moving its database?
layerbase.com/blog/railway-o…
Did DocumentDB V1 and DuckDB V2 really both need to release on the same day?
This is fine...
BTW - both coming to Layerbase this week (unless we decide to sleep)
couchdb mango queries with no index don't fail, they quietly scan every doc. ask for the numbers
POST /orders/_find
{"selector":{"status":"paid"},"execution_stats":true}
docs examined way over results returned means add an index. on 3.5+ "allow_fallback":false errors instead
influxdb 3 fills empty time buckets
SELECT date_bin_gapfill(INTERVAL '5 minutes', time),
locf(avg(usage))
FROM cpu
WHERE time >= '2026-10-20T08:00:00Z'
AND time <= '2026-10-20T09:00:00Z'
GROUP BY 1
locf repeats the last value, interpolate() draws a line. needs both bounds
releasing a lock in valkey used to mean a lua script. on 9.0+ it's one command
SET lock:job worker-42 NX PX 30000
...
DELIFEQ lock:job worker-42
it only deletes if the value is still yours, so you can't free a lock someone else grabbed after yours expired
meilisearch will score every hit from 0 to 1, you just have to ask
POST /indexes/products/search
{"q":"red shoes","showRankingScore":true,"rankingScoreThreshold":0.5}
the threshold drops weak matches, so "no results" can actually mean no results instead of a page of junk
mariadb will keep a table's full history for you, no audit triggers
ALTER TABLE prices ADD SYSTEM VERSIONING;
then read it as it was at any moment after that
SELECT * FROM prices FOR SYSTEM_TIME AS OF TIMESTAMP'2026-10-16 09:00:00';
FOR SYSTEM_TIME ALL shows every version
an ALTER TABLE stuck waiting behind one slow query also blocks every query that shows up after it. set a lock_timeout first so it gives up instead
SET lock_timeout = '3s';
ALTER TABLE orders ADD COLUMN note text;
if it times out, just retry. beats a pileup
qdrant can do "more like this, less like that" with point ids
POST /collections/items/points/query
{"query":{"recommend":{"positive":[100,231],"negative":[718]}},"limit":5}
pulls the vectors already stored, so you skip re-embedding
mysql lets you soft delete an index. the optimizer ignores it, writes still keep it warm
ALTER TABLE orders ALTER INDEX idx_user_id INVISIBLE;
check EXPLAIN, flip it VISIBLE if you guessed wrong. cheaper than drop + recreate. mysql 8.0+
latest row per key in questdb, no window function needed
SELECT symbol, price, timestamp
FROM trades
LATEST ON timestamp PARTITION BY symbol
one row per symbol, the newest. the table needs a designated timestamp
top N per group in clickhouse, no window function needed
SELECT user_id, path, ts
FROM events
ORDER BY user_id, ts DESC
LIMIT 3 BY user_id
latest 3 events per user. stack a normal LIMIT after it to cap the total rows


