ワンクリックで
mysql
Query and manage MySQL databases using mysql CLI. Connect to PlanetScale, AWS RDS, Google Cloud SQL, or any MySQL instance.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Query and manage MySQL databases using mysql CLI. Connect to PlanetScale, AWS RDS, Google Cloud SQL, or any MySQL instance.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
Eliminate AI-sounding patterns from any written output. Applies editorial rules synthesized from the best open-source anti-slop tools: banned phrases, structural pattern detection, false agency checks, and a scoring rubric. Use as a quality gate for ANY content — blog posts, social media, emails, documentation, marketing copy. Triggers on: "make it sound human", "less AI", "remove slop", "humanize this", "doesn't sound natural", "too AI", "rewrite naturally", or when reviewing any AI-generated text before publishing.
AWS Bedrock AgentCore comprehensive expert for deploying and managing all AgentCore services. Use when working with Gateway, Runtime, Memory, Identity, or any AgentCore component. Covers MCP target deployment, credential management, schema optimization, runtime configuration, memory management, and identity services.
AWS Cloud Development Kit (CDK) expert for building cloud infrastructure with TypeScript/Python. Use when creating CDK stacks, defining CDK constructs, implementing infrastructure as code, or when the user mentions CDK, CloudFormation, IaC, cdk synth, cdk deploy, or wants to define AWS infrastructure programmatically. Covers CDK app structure, construct patterns, stack composition, and deployment workflows.
This skill provides AWS cost optimization, monitoring, and operational best practices with integrated MCP servers for billing analysis, cost estimation, observability, and security assessment.
AWS serverless and event-driven architecture expert based on Well-Architected Framework. Use when building serverless APIs, Lambda functions, REST APIs, microservices, or async workflows. Covers Lambda with TypeScript/Python, API Gateway (REST/HTTP), DynamoDB, Step Functions, EventBridge, SQS, SNS, and serverless patterns. Essential when user mentions serverless, Lambda, API Gateway, event-driven, async processing, queues, pub/sub, or wants to build scalable serverless applications with AWS best practices.
A comprehensive collection of Agent Skills for context engineering, multi-agent architectures, and production agent systems. Use when building, optimizing, or debugging agent systems that require effective context management.
| name | mysql |
| description | Query and manage MySQL databases using mysql CLI. Connect to PlanetScale, AWS RDS, Google Cloud SQL, or any MySQL instance. |
| version | 1.0.0 |
| allowed-tools | Bash |
| metadata | {"credentials":["MYSQL_URL","MYSQL_HOST","MYSQL_USER","MYSQL_PASSWORD","MYSQL_DATABASE"]} |
Query and manage MySQL databases using the mysql CLI.
# Using individual variables
mysql -h "$MYSQL_HOST" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" "$MYSQL_DATABASE" -e "SELECT count(*) FROM users"
Configure credentials as Space environment variables.
| Variable | Description | Example |
|---|---|---|
MYSQL_HOST | Database host | db.example.com |
MYSQL_USER | Database user | readonly |
MYSQL_PASSWORD | Database password | secret123 |
MYSQL_DATABASE | Database name | myapp |
MYSQL_PORT | Port (optional, default 3306) | 3306 |
Or use a URL and parse it:
| Variable | Description | Example |
|---|---|---|
MYSQL_URL | Full connection URL | mysql://user:pass@host:3306/dbname |
if [ -n "$MYSQL_URL" ]; then
MYSQL_USER=$(echo "$MYSQL_URL" | sed -E 's|mysql://([^:]+):.*|\1|')
MYSQL_PASSWORD=$(echo "$MYSQL_URL" | sed -E 's|mysql://[^:]+:([^@]+)@.*|\1|')
MYSQL_HOST=$(echo "$MYSQL_URL" | sed -E 's|mysql://[^@]+@([^:/]+).*|\1|')
MYSQL_PORT=$(echo "$MYSQL_URL" | sed -E 's|mysql://[^@]+@[^:]+:([0-9]+).*|\1|')
MYSQL_DATABASE=$(echo "$MYSQL_URL" | sed -E 's|mysql://[^/]+/([^?]+).*|\1|')
MYSQL_PORT="${MYSQL_PORT:-3306}"
fi
mysql -h "$MYSQL_HOST" -P "${MYSQL_PORT:-3306}" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" "$MYSQL_DATABASE" -e "SELECT version()"
mysql -h "$MYSQL_HOST" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" "$MYSQL_DATABASE" -e "SELECT * FROM users LIMIT 10"
mysql -h "$MYSQL_HOST" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" "$MYSQL_DATABASE" -e "SHOW TABLES"
mysql -h "$MYSQL_HOST" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" "$MYSQL_DATABASE" -e "DESCRIBE users"
mysql -h "$MYSQL_HOST" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" "$MYSQL_DATABASE" -e "
SELECT table_name,
ROUND(data_length/1024/1024, 2) AS data_mb,
ROUND(index_length/1024/1024, 2) AS index_mb,
table_rows
FROM information_schema.tables
WHERE table_schema = '$MYSQL_DATABASE'
ORDER BY data_length DESC"
mysql -h "$MYSQL_HOST" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" "$MYSQL_DATABASE" -e "SELECT count(*) FROM users"
mysql -h "$MYSQL_HOST" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" "$MYSQL_DATABASE" -B -e "SELECT * FROM users" | tr '\t' ',' > users.csv
mysql -h "$MYSQL_HOST" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" "$MYSQL_DATABASE" -N -e "
SELECT JSON_ARRAYAGG(JSON_OBJECT('id', id, 'email', email, 'name', name))
FROM users LIMIT 100" > users.json
mysql -h "$MYSQL_HOST" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" "$MYSQL_DATABASE" < dump.sql
mysql -h "$MYSQL_HOST" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" "$MYSQL_DATABASE" --local-infile -e "
LOAD DATA LOCAL INFILE 'data.csv' INTO TABLE users
FIELDS TERMINATED BY ',' ENCLOSED BY '\"'
LINES TERMINATED BY '\n'
IGNORE 1 ROWS (name, email)"
mysql -h "$MYSQL_HOST" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" "$MYSQL_DATABASE" -e "SHOW CREATE TABLE users\G"
mysql -h "$MYSQL_HOST" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" "$MYSQL_DATABASE" -e "SHOW INDEX FROM users"
mysql -h "$MYSQL_HOST" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" -e "SHOW DATABASES"
mysql -h "$MYSQL_HOST" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" "$MYSQL_DATABASE" -e "INSERT INTO users (name, email) VALUES ('John', 'john@example.com')"
mysql -h "$MYSQL_HOST" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" "$MYSQL_DATABASE" -e "UPDATE users SET name = 'Jane' WHERE id = 1"
mysql -h "$MYSQL_HOST" -u "$MYSQL_USER" -p"$MYSQL_PASSWORD" "$MYSQL_DATABASE" -e "DELETE FROM users WHERE id = 1"
aws.connect.psdb.cloud--ssl-mode=VERIFY_IDENTITY --ssl-ca=/etc/ssl/certs/ca-certificates.crt[instance].[region].rds.amazonaws.com--ssl-mode=REQUIRED for encrypted connections| Error | Cause | Solution |
|---|---|---|
Can't connect to MySQL server | Host unreachable | Check MYSQL_HOST, firewall rules |
Access denied | Wrong credentials | Verify MYSQL_USER/MYSQL_PASSWORD |
Unknown database | Database doesn't exist | Check MYSQL_DATABASE name |
SSL connection error | SSL required | Add --ssl-mode=REQUIRED flag |
Table doesn't exist | Wrong table name | Run SHOW TABLES first |
LIMIT when exploring — avoid dumping entire tables-e flag for single queries, pipe from files for multi-statement SQL\G suffix instead of ; for vertical display of wide rows-B flag for batch mode (tab-separated, no table borders) — good for scripting-N flag to suppress column headers-p"$MYSQL_PASSWORD" (no space after -p)--ssl-mode=REQUIRED