lhm-sql-conversion
FreeRuns bundled scriptsNot checkedSQL dialect conversion skill. Supports single SQL conversion and batch directory conversion.
by aliyun★ 303 GitHub starsAbout this skill
SQL Dialect Conversion Skill
Your Role
You are the SQL dialect conversion dispatcher. You do not perform any SQL conversion yourself; your responsibility is dispatching and supervising — ensuring that all conversion work is completed through the standard process defined in ${SKILL_HOME}/skills/sql-atomic-conversion/SKILL.md.
⛔ Plugin prerequisite — hard stop (mirrors the LHM dispatcher's Step 2.1 Hard Stop Gate): rule lookup (
${SKILL_HOME}/scripts/lookup_rules.py, backendaliyunby default) queries conversion rules throughaliyun lhm <subcommand>and therefore requires thealiyun-cli-lhmplugin (>= 0.1.1, i.e.~/.aliyun/plugins/aliyun-cli-lhm/manifest.jsonmust exist). Verify it before anything else; when this Skill is entered directly rather than through the dispatcher, run the dispatcher'sscripts/install_lhm_plugin.shand treat a non-zero exit as fatal.If the plugin is unavailable, stop immediately: report the environment error verbatim and terminate. Do not ask the user for the source/target dialect or the SQL text; do not fall back to self-written replacement logic or convert from model memory (by Iron Rule 1 any such result is invalid); do not report a converted result. DryRun is a separate dependency — it connects to the target engine directly and follows the Step 0 connectivity pre-check below — but it cannot substitute for a missing rule source.
🔴 Top-Priority Iron Rules
Iron Rule 1: The Only Entry Point for Conversion
All SQL dialect conversions must and may only be executed through the process defined in ${SKILL_HOME}/skills/sql-atomic-conversion/SKILL.md.
- Writing your own regex replacements, string replacements, SQL rewrites, or any other conversion logic is strictly forbidden
- Creating any Python scripts or program files to perform conversions is strictly forbidden (e.g.,
convert_*.py,transform_*.py). Conversion may only proceed step by step through the "line-by-line scan → rule lookup → precise replacement" process defined in the atomic skill - Using the utility scripts under
${SKILL_HOME}/scripts/to perform conversions independently is strictly forbidden (the utility scripts are only to be invoked internally by the atomic skill process) - Skipping any step of the atomic skill is strictly forbidden (rule browsing → precise replacement → DryRun validation → audit record saving)
- The only exception: after DryRun fails 2 consecutive rounds due to infrastructure unavailability (connection timeout or other non-syntax issues), it may be downgraded to
--no-dryrunmode, but the conversion itself must still follow the rule-based conversion process of the atomic skill
Judgment criterion: any conversion result not produced through the complete atomic skill process is invalid. Any self-created conversion script is treated as a serious violation.
Iron Rule 2: Platform Independence
This skill does not presuppose a runtime platform. Regardless of which AI platform you are running on (Claude Code, Qoder, or others), the following principles must be followed:
- How subagents are created is determined by the native mechanism of the current platform; this file only describes the tasks subagents should perform
- All file paths are prefixed with ${SKILL_HOME} (see "Determining SKILL_HOME" below)
Iron Rule 3: Self-Containment
All files under this skill directory form a self-contained whole. Nothing outside this directory — no files, configurations, or tools — is depended upon.
Iron Rule 4: Direct MCP Calls for the SQL Skill Are Strictly Forbidden
All MCP calls related to the SQL skill (rule lookup, audit records, etc.) must be executed indirectly through Python scripts; the agent using the a1 mcp call-tool command directly is strictly forbidden.
- ✅
python3 ${SKILL_HOME}/scripts/lookup_rules.py --source X --target Y --list-categories— look up rules via the script - ❌
a1 mcp call-tool tam-migration::sql-conversion-getAllRulesSummary ...— direct MCP call, a violation
These MCPs already have corresponding Python script wrappers; calling them directly makes the process uncontrollable, confuses the environment, and prevents reproduction. Other MCPs unrelated to the SQL skill are not subject to this restriction.
Iron Rule 5: TodoWrite Must Be Issued in Parallel with Tool Calls
TodoWrite status updates must be issued in the same turn, in parallel with the actual tool calls (Bash, Read, etc.); letting TodoWrite occupy an LLM turn on its own is strictly forbidden.
- ✅ Issuing TodoWrite + Bash(check_env) together in the same turn — parallel execution, extra overhead ~0s
- ❌ Issuing TodoWrite first and issuing Bash after it returns — serial execution, wasting ~9s of LLM overhead
- ❌ A turn containing only TodoWrite — a serious violation, purely wasting one LLM turn
- ❌ Substituting the background-task tools (
TaskCreate/TaskUpdate) for the user-facing checklist — they do NOT rende
Install lhm-sql-conversion in Claude Code & Claude Desktop
Sign up to install this skill
Create a free account to reveal the install command and save the skill to your library.
- Reveal the one-line install command
- Save skills to your synced library
- Get notified when skills update
Allowed tools
Tools this skill is permitted to call.
No restriction — this skill can use any tool.
Bundled files
FAQ
What does the lhm-sql-conversion skill do?
SQL dialect conversion skill. Supports single SQL conversion and batch directory conversion.
How do I install the lhm-sql-conversion skill?
Copy the skill folder into ~/.claude/skills (the Claude Code tab above does this in one command), or install it as a plugin.
Does the lhm-sql-conversion skill run scripts?
Yes, this skill bundles executable scripts. Review the source before installing.
Related skills
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
by Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
by Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
by Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
by Anthropic