miolo-database

Standardize database query patterns and IO structure for miolo applications.

Updated Feb 4, 2022
One-click install
npx skills add https://github.com/afialapis/miolo --skill miolo-database
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: miolo-database
Source: https://github.com/afialapis/miolo/tree/main/skills/miolo-database
Command: npx skills add https://github.com/afialapis/miolo --skill miolo-database

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Database query patterns and an organized IO structure for miolo applications, enabling consistent, readable, and maintainable data access across the codebase.

Core Features & Use Cases

  • Domain-based organization under src/server/db/io, with clear separation of queries by feature.
  • Consistent naming convention for data access: db_[domain]_[action], improving discoverability and traceability.
  • CRUD templates, safe query execution (parameterization, ownership checks), and a shared make_query_filter helper to build dynamic WHERE clauses.
  • Configuration, migrations, and best practices to enforce secure and scalable data access across environments.

Quick Start

Start by organizing your queries under src/server/db/io, implement the db_[domain]_[action] pattern, and adopt the make_query_filter helper for building where clauses.

Frequently Asked Questions about miolo-database

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I standardize PostgreSQL data access patterns across my codebase?

Standardize PostgreSQL data access by organizing domain-based folders under src/server/db/io and applying the db_[domain]_[action] naming convention. This enforces consistent query construction and maintainable CRUD operations across the application.

What is the best way to build dynamic SQL WHERE clauses safely?

Build dynamic SQL WHERE clauses safely using the shared make_query_filter helper. It standardizes filter construction to support secure, parameterized query execution across domain-based data access layers.

How do I structure database migrations and IO for consistent domain queries?

Structure database migrations and IO by separating queries by feature under dedicated domain folders. Apply consistent naming conventions and configuration best practices to enforce secure and scalable data access across environments.

Can I use this pattern to enforce ownership checks in PostgreSQL CRUD operations?

Yes, you can enforce ownership checks in PostgreSQL CRUD operations using the provided templates. These templates integrate parameterization and safe query execution to ensure secure, maintainable data access.

Why should I use a standardized database IO structure for application queries?

Use a standardized database IO structure to improve consistency, readability, and traceability. The db_[domain]_[action] convention ensures deterministic operations and secure query execution across the codebase.

Does this database pattern support deterministic CRUD operations for domain features?

Yes, this database pattern supports deterministic CRUD operations for domain features. By standardizing query patterns and IO structure under src/server/db/io, it enables consistent and safe data access.