Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Work with MongoDB (document database, BSON documents, aggregation pipelines, Atlas cloud) and PostgreSQL (relational database, SQL queries, psql CLI, pgAdmin). Use when designing database schemas, writing queries and aggregations, optimizing indexes for performance, performing database migrations, configuring replication and sharding, implementing backup and restore strategies, managing database users and permissions, analyzing query performance, or administering production databases.
.claude/skills/microck-databases/SKILL.md| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-04 | ✗→✓ | ▲ Improved | 75% | 0% |
| case-01 | ✗→✓ | ▲ Improved | 49% | 0% |
| case-02 | ✗→✓ | ▲ Improved | 128% | 0% |
| case-11 | ✗→✓ | ▲ Improved | 71% | 0% |
| case-05 | ✓→✓ | = Same ✓ | 208% | 0% |
Unified guide for working with MongoDB (document-oriented) and PostgreSQL (relational) databases. Choose the right database for your use case and master both systems.
Use when:
Best for: Content management, catalogs, IoT time series, real-time analytics, mobile apps, user profiles
Best for: Financial systems, e-commerce transactions, ERP, CRM, data warehousing, analytics
bash# Atlas (Cloud) - Recommended # 1. Sign up at mongodb.com/atlas # 2. Create M0 free cluster # 3. Get connection string # Connection mongodb+srv://user:pass@cluster.mongodb.net/db # Shell mongosh "mongodb+srv://cluster.mongodb.net/mydb" # Basic operations db.users.insertOne({ name: "Alice", age: 30 }) db.users.find({ age: { $gte: 18 } }) db.users.updateOne({ name: "Alice" }, { $set: { age: 31 } }) db.users.deleteOne({ name: "Alice" })
bash# Ubuntu/Debian sudo apt-get install postgresql postgresql-contrib # Start service sudo systemctl start postgresql # Connect psql -U postgres -d mydb # Basic operations CREATE TABLE users (id SERIAL PRIMARY KEY, name TEXT, age INT); INSERT INTO users (name, age) VALUES ('Alice', 30); SELECT * FROM users WHERE age >= 18; UPDATE users SET age = 31 WHERE name = 'Alice'; DELETE FROM users WHERE name = 'Alice';
javascript// MongoDB db.users.insertOne({ name: "Bob", email: "bob@example.com" }) db.users.insertMany([{ name: "Alice" }, { name: "Charlie" }])
sql-- PostgreSQL INSERT INTO users (name, email) VALUES ('Bob', 'bob@example.com'); INSERT INTO users (name, email) VALUES ('Alice', NULL), ('Charlie', NULL);
javascript// MongoDB db.users.find({ age: { $gte: 18 } }) db.users.findOne({ email: "bob@example.com" })
sql-- PostgreSQL SELECT * FROM users WHERE age >= 18; SELECT * FROM users WHERE email = 'bob@example.com' LIMIT 1;
javascript// MongoDB db.users.updateOne({ name: "Bob" }, { $set: { age: 25 } }) db.users.updateMany({ status: "pending" }, { $set: { status: "active" } })
sql-- PostgreSQL UPDATE users SET age = 25 WHERE name = 'Bob'; UPDATE users SET status = 'active' WHERE status = 'pending';
javascript// MongoDB db.users.deleteOne({ name: "Bob" }) db.users.deleteMany({ status: "deleted" })
sql-- PostgreSQL DELETE FROM users WHERE name = 'Bob'; DELETE FROM users WHERE status = 'deleted';
javascript// MongoDB db.users.createIndex({ email: 1 }) db.users.createIndex({ status: 1, createdAt: -1 })
sql-- PostgreSQL CREATE INDEX idx_users_email ON users(email); CREATE INDEX idx_users_status_created ON users(status, created_at DESC);
Database utility scripts in scripts/:
bash# Generate migration python scripts/db_migrate.py --db mongodb --generate "add_user_index" # Run backup python scripts/db_backup.py --db postgres --output /backups/ # Check performance python scripts/db_performance_check.py --db mongodb --threshold 100ms
| Feature | MongoDB | PostgreSQL | |---------|---------|------------| | Data Model | Document (JSON/BSON) | Relational (Tables/Rows) | | Schema | Flexible, dynamic | Strict, predefined | | Query Language | MongoDB Query Language | SQL | | Joins | $lookup (limited) | Native, optimized | | Transactions | Multi-document (4.0+) | Native ACID | | Scaling | Horizontal (sharding) | Vertical (primary), Horizontal (extensions) | | Indexes | Single, compound, text, geo, etc | B-tree, hash, GiST, GIN, etc |
MongoDB:
PostgreSQL:
| Case | Status | Duration (ms) | Turns | Tokens | Tool calls | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Without | With | Δ | Without | With | Δ | Without | With | Δ | Without | With | Δ | ||
case-05 | pass→pass | 5,589 | 7,076 | +27% | 1 | 1 | 0% | 933 | 2,874 | +208% | 0 | 0 | — |
case-04 | fail→pass | 11,431 | 8,740 | -24% | 1 | 1 | 0% | 2,051 | 3,588 | +75% | 0 | 0 | — |
case-01 | fail→pass | 11,227 | 6,880 | -39% | 1 | 1 | 0% | 1,947 | 2,900 | +49% | 0 | 0 | — |
case-02 | fail→pass | 6,873 | 5,458 | -21% | 1 | 1 | 0% | 1,203 | 2,744 | +128% | 0 | 0 | — |
case-03 | pass→pass | 12,923 | 13,536 | +5% | 1 | 1 | 0% | 2,263 | 4,103 | +81% | 0 | 0 | — |
case-06 | pass→pass | 18,992 | 13,517 | -29% | 1 | 1 | 0% | 2,976 | 3,927 | +32% | 0 | 0 | — |
case-07 | pass→pass | 15,855 | 13,932 | -12% | 1 | 1 | 0% | 2,562 | 4,362 | +70% | 0 | 0 | — |
case-08 | pass→pass | 6,937 | 3,469 | -50% | 1 | 1 | 0% | 1,021 | 2,481 | +143% | 0 | 0 | — |
case-09 | pass→pass | 5,324 | 4,489 | -16% | 1 | 1 | 0% | 887 | 2,511 | +183% | 0 | 0 | — |
case-10 | pass→pass | 4,597 | 4,480 | -3% | 1 | 1 | 0% | 759 | 2,621 | +245% | 0 | 0 | — |
case-11 | fail→pass | 8,295 | 1,774 | -79% | 1 | 1 | 0% | 1,243 | 2,128 | +71% | 0 | 0 | — |
case-12 | fail→fail | 9,933 | 2,662 | -73% | 1 | 1 | 0% | 1,715 | 2,137 | +25% | 0 | 0 | — |
case-13 | pass→pass | 5,867 | 4,595 | -22% | 1 | 1 | 0% | 880 | 2,471 | +181% | 0 | 0 | — |
case-14 | pass→pass | 12,893 | 13,763 | +7% | 1 | 1 | 0% | 2,006 | 3,776 | +88% | 0 | 0 | — |
case-15 | pass→pass | 11,911 | 7,857 | -34% | 1 | 1 | 0% | 1,891 | 3,156 | +67% | 0 | 0 | — |
case-16 | pass→pass | 11,078 | 8,646 | -22% | 1 | 1 | 0% | 1,662 | 3,199 | +92% | 0 | 0 | — |
case-17 | pass→pass | 3,692 | 5,365 | +45% | 1 | 1 | 0% | 563 | 2,692 | +378% | 0 | 0 | — |
case-18 | pass→pass | 3,997 | 2,967 | -26% | 1 | 1 | 0% | 651 | 2,297 | +253% | 0 | 0 | — |
case-19 | pass→pass | 3,136 | 2,950 | -6% | 1 | 1 | 0% | 375 | 2,250 | +500% | 0 | 0 | — |
case-20 | pass→pass | 2,692 | 2,562 | -5% | 1 | 1 | 0% | 383 | 2,232 | +483% | 0 | 0 | — |
case-21 | pass→pass | 4,323 | 3,751 | -13% | 1 | 1 | 0% | 753 | 2,422 | +222% | 0 | 0 | — |
case-22 | pass→pass | 3,145 | 2,590 | -18% | 1 | 1 | 0% | 426 | 2,162 | +408% | 0 | 0 | — |
DecimalAI ran this skill against gemini-3.6-flash twice over the same eval suite — once with the skill loaded and once without — and compared the two runs case by case. 22 cases were attempted. The headline lift of +18 percentage points is the difference between those two pass rates over the 22 comparable cases.
Without the skill loaded, the model failed this case. With it loaded, the same prompt on the same model passed. This is one improved case from the latest verified run; every case, including any that regressed, is in the table above.
Other measured skills in the registry, with their headline benchmark lift.