Skip to main content
skill CX Codex

alibabacloud-polardbx-sql — Claude Code skill

alibabacloud-polardbx-sql — a skill for writing SQL on distributed PolarDB-X 2.0 Enterprise Edition databases in AUTO mode, designing partition schemes, and avoiding MySQL incompatibilities.

no license 180 installs ★ 300 updated 2026-10-23

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add aliyun/alibabacloud-aiops-skills --skill alibabacloud-polardbx-sql -a claude-code
Open on GitHub

What alibabacloud-polardbx-sql does

This skill targets PolarDB-X 2.0 Enterprise Edition in AUTO mode, where tables use standard PARTITION BY syntax. If your database runs DRDS mode or Standard Edition, the skill refuses and directs you to the right tool.

The skill provides logic to select partition keys by analyzing query frequency, cardinality, and hotspot risk; create global indexes (GSI and CCI); convert single-node tables to partitioned ones; and handle Sequence, table groups, and TTL. It teaches how to write queries that avoid full-cluster scans and handles pagination via Keyset.

Before any operation, the skill requires explicit confirmation of connection parameters: host, port, user, password, and database name. Commands do not execute without approval.

What it helps with

  • Design a partition scheme for a large table so queries hit one or a few shards instead of scanning the entire cluster
  • Choose a partition key from multiple candidates by analyzing SQL patterns and data distribution
  • Convert a MySQL table to a PolarDB-X partitioned table without data loss
  • Create a global index (GSI or CCI) to speed up queries on non-partition-key fields
  • Diagnose slow queries and understand why they trigger full-cluster scans

Example prompts for the agent

  • Help me pick the right partition key for an orders table based on its query patterns
  • Write SQL to convert my single users table to a partitioned table sharded by region_id in AUTO mode
  • Why does a query on created_at in the products table scan all shards, and how do I speed it up with GSI?

How to install alibabacloud-polardbx-sql

1Skills CLI (Vercel)

npx skills add aliyun/alibabacloud-aiops-skills --skill alibabacloud-polardbx-sql -a claude-code

2Manually: put the files in place

~/.claude/skills/alibabacloud-polardbx-sql/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/alibabacloud-polardbx-sql/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about alibabacloud-polardbx-sql

How do I install alibabacloud-polardbx-sql in Claude Code?

Run npx skills add aliyun/alibabacloud-aiops-skills --skill alibabacloud-polardbx-sql -a claude-code, then check ~/.claude/skills/alibabacloud-polardbx-sql/SKILL.md.

What does alibabacloud-polardbx-sql do?

It helps design partitions, choose partition keys, create GSI/CCI indexes, and write SQL for PolarDB-X 2.0 Enterprise Edition in AUTO mode while accounting for differences from MySQL.

Does this skill work with PolarDB-X 1.0 or Standard Edition?

No. The skill is for PolarDB-X 2.0 Enterprise Edition in AUTO mode only. For DRDS 1.0 or Standard Edition, the skill refuses and recommends the correct tool.

Similar skills

All skills for Data and databases →

From the same set66

The whole set →
alibabacloud-ecs-install-extension alibabacloud-ecs-install-extension is a Claude Code skill for browsing Alibaba Cloud ECS packages, checking compatibility, and installing extensions such as Python and Node.js with one click. CX Codex +1 186installs alibabacloud-solution-deploy The alibabacloud-solution-deploy skill automates deployment of official Alibaba Cloud solutions via Terraform or CLI. Use it to spin up ready-made architectures—from RAG systems to web applications—without clicking through the console. CX Codex +1 182installs alibabacloud-sas-incident-manage alibabacloud-sas-incident-manage queries Alibaba Cloud Security Center for incidents, incident details, and threat trends through Cloud SIEM and Aliyun CLI. CX Codex +1 181installs alibabacloud-data-agent-skill alibabacloud-data-agent-skill connects your coding assistant to Alibaba Cloud Apsara Data Agent for natural language database queries and automated reports. CX Codex +1 180installs alibabacloud-emr-starrocks-manage alibabacloud-emr-starrocks-manage — a skill for Alibaba Cloud EMR Serverless StarRocks lifecycle management: create, scale, configure, and troubleshoot instances via CLI. Use it when SREs or architects need to automate StarRocks operations. CX Codex +1 176installs alibabacloud-esa-pages-deploy alibabacloud-esa-pages-deploy deploys HTML files, frontend build folders, and custom JavaScript edge functions to Alibaba Cloud ESA nodes with Edge KV management. CX Codex +1 176installs alibabacloud-dts-task-query alibabacloud-dts-task-query polls the Alibaba Cloud CLI for DTS job state in every region, then prints a Chinese report grouped by type with filters for instance or job name. CX Codex +1 174installs alibabacloud-mongodb-instances-manage alibabacloud-mongodb-instances-manage controls Alibaba Cloud ApsaraDB for MongoDB deployments via your coding agent. Useful for managing standalone nodes, replica sets, and cluster scaling. CX Codex +1 174installs

Project sponsors

Companies that keep this analytics open