원클릭으로
sherlock
Allows read-only access to SQL databases and Redis for querying and analysis using natural language
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Allows read-only access to SQL databases and Redis for querying and analysis using natural language
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
| name | sherlock |
| description | Allows read-only access to SQL databases and Redis for querying and analysis using natural language |
| allowed-tools | ["Bash(~/.claude/skills/sherlock/sherlock:*)"] |
Read-only database access for SQL and Redis. Binary: ~/.claude/skills/sherlock/sherlock
--url)Use --url (-u) to connect directly via a database URL without any config file setup. This is ideal when a project has a DATABASE_URL in its .env file.
sherlock -u "postgres://user:pass@localhost:5432/mydb" tables
sherlock -u "mysql://user:pass@localhost:3306/mydb" query "SELECT 1"
sherlock -u "redis://localhost:6379" info
--url and -c are mutually exclusive — use one or the otherpostgres://, mysql://, sqlite://, redis://)When to use --url vs -c: Use --url for quick one-off access, especially when the project already has a DATABASE_URL. Use -c for repeated access to the same database with config-managed credentials.
All SQL commands require -c <connection> or -u <url>. Output is JSON by default, use -f markdown for tables.
sherlock connections # List available connections
sherlock -c <conn> tables # List tables
sherlock -c <conn> describe <table> # Table schema
sherlock -c <conn> introspect # Full schema (cached)
sherlock -c <conn> introspect --refresh # Refresh cached schema
sherlock -c <conn> query "SELECT ..." # Execute read-only query
sherlock -c <conn> sample <table> -n 10 # Random sample rows
sherlock -c <conn> stats <table> # Data profiling (nulls, distinct counts)
sherlock -c <conn> indexes <table> # Table indexes
sherlock -c <conn> fk <table> # Foreign key relationships
All Redis commands require -c <connection> pointing to a Redis connection.
sherlock -c <conn> info # Server info, memory, keyspace
sherlock -c <conn> info --section memory # Specific INFO section
sherlock -c <conn> keys "user:*" # Scan for keys matching pattern
sherlock -c <conn> keys --limit 50 # Limit number of results
sherlock -c <conn> get <key> # Get value (auto-detects type)
sherlock -c <conn> get <key> --limit 50 # Limit items for lists/sets/zsets
sherlock -c <conn> inspect <key> # Key metadata (type, TTL, memory, encoding)
sherlock -c <conn> slowlog # Recent slow queries
sherlock -c <conn> slowlog -n 20 # Last 20 slow log entries
sherlock -c <conn> command GET mykey # Execute any read-only Redis command
-c <connection> or -u <url> (no default)"identifier", MySQL uses `identifier`connections to see available databasestables or introspect to understand schema (introspect is cached per-connection)fk to understand table relationships before writing JOINssample to see real data examples before writing queriesquery, present results clearlyconnections to see available connectionsinfo to understand the Redis instance (version, memory, keyspace)keys "pattern:*" to find keys of interestget <key> to retrieve values (auto-detects string/hash/list/set/zset)inspect <key> for metadata (TTL, memory usage, encoding)command for any other read-only operationstats for SQL data profiling (row counts, null counts, distinct values)-f markdown for human-readable table outputkeys with specific patterns rather than * on large databases--no-types with keys for faster scanning when type info isn't needed~/.claude/skills/sherlock/config.json