A read-only query tool for Microsoft SQL Server that connects to multiple databases through a JSON config file. It validates queries to block writes (INSERT, UPDATE, DELETE), enforces timeouts, and caps results at 10,000 rows to prevent memory issues. The intelligent database selection matches user intent to database descriptions, so you can ask about "orders" and it routes to the right connection. Practical for exploring schemas, running analytics queries, and checking production data without the risk of accidental modifications. Setup requires creating a credentials file with proper permissions, and it handles TDS protocol versions and TLS encryption for Azure SQL connections. Works through a Python CLI with flags for listing databases, showing schemas, and running queries with automatic TOP N conversion.

skills.sh installs
549
GitHub stars
454
last updated
Aug 21, 2026

Install

$ npx -y skills add sanjay3290/ai-skills --skill mssql --agent claude-code

Installs into .claude/skills of the current project.

Files

MSSQL Read-Only Query Skill

Execute safe, read-only queries against configured Microsoft SQL Server databases.

Requirements

  • Python 3.8+
  • pymssql: pip install -r requirements.txt

Setup

Create connections.json in the skill directory or ~/.config/claude/mssql-connections.json.

Security: Set file permissions to 600 since it contains credentials:

chmod 600 connections.json
{
  "databases": [
    {
      "name": "production",
      "description": "Main app database - users, orders, transactions",
      "host": "db.example.com",
      "port": 1433,
      "database": "app_prod",
      "user": "readonly_user",
      "password": "your-password",
      "encrypt": true,
      "tds_version": "7.3"
    }
  ]
}

Config Fields

Sponsors

Details

Repository
github.com/sanjay3290/ai-skills
Categories
Backend & APIs, AI & Agent Building, Databases
License
Apache-2.0
First seen
Jun 3, 2026

More from sanjay3290/ai-skills

All 20
1aicoincom avataraicoin-accountaicoincom/coinos-skillsExchange account management: balance, positions, order history, registration, API key setup, tier upgrade. **用户问'我的'账户事件 / 活跃记录 / 活动 / 操作日志 / 登录历史 / 下单历史 / 最近操作548skills.sh installs
2sanjay3290 avatargoogle-calendarsanjay3290/ai-skillsInteract with Google Calendar - list calendars, view events, create/update/delete events, and find free time. Use when user asks to: check calendar, schedule a 544skills.sh installs
3vintasoftware avatarcdrf-expertvintasoftware/django-ai-pluginsExpert guidance for Django REST Framework class-based views using Classy DRF (https://www.cdrf.co). Use when selecting or debugging APIView, GenericAPIView, con544skills.sh installs
4awslabs avatardsqlawslabs/mcpBuild with Aurora DSQL — manage schemas, execute queries, handle migrations, diagnose query plans, load data, and develop applications with a serverless, distri541skills.sh installs
5hkuds avatarcli-anything-chromadbhkuds/cli-anythingCommand-line interface for ChromaDB - A stateless CLI for managing vector database collections, documents, and semantic search. Designed for AI agents and autom540skills.sh installs
6manutej avatarenterprise-architecture-patternsmanutej/luxor-claude-marketplaceComplete guide for enterprise architecture patterns including domain-driven design, event sourcing, CQRS, saga patterns, API gateway, service mesh, and scalabil530skills.sh installs