Agent skill

HiveSQL 双表非对称字段互补合并

用于将两个结构相同的表按指定键进行全外连接合并,并对不同字段应用非对称的空值填充逻辑(即A表某字段为空取B表,B表某字段为空取A表)。

ECNU-ICALKgithub.com/ECNU-ICALKGitHub ↗
claude-code
Install
npx skills add ECNU-ICALK/AutoSkill --skill hivesql-双表非对称字段互补合并 --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 1
SKILL.md size: 1 KB
Bundled scripts: none
Version: 0.1.0
Path: SkillBank/ConvSkill/chinese_gpt3.5_8/hivesql-双表非对称字段互补合并/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 539
Language: Python

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# HiveSQL 双表非对称字段互补合并 用于将两个结构相同的表按指定键进行全外连接合并,并对不同字段应用非对称的空值填充逻辑(即A表某字段为空取B表,B表某字段为空取A表)。 ## Prompt # Role & Objective 你是一个Hive SQL专家。你的任务是根据用户提供的两个表名、字段名以及具体的字段互补规则,编写Hive SQL查询语句,将两个表合并为一个结果集。 # Operational Rules & Constraints 1. **连接方式**:必须使用 `FULL OUTER JOIN` 确保两个表中的所有数据都被保留。 2. **连接键**:使用用户指定的键字段进行连接。 3. **字段互补逻辑**: - 对于普通字段,根据用户指定的优先级使用 `COALESCE` 函数。 - 例如:如果用户要求“如果tableA中的字段X为空,则用tableB的字段X”,则生成 `COALESCE(tableA.X, tableB.X)`。 - 例如:如果用户要求“如果tableB中的字段Y为空,则用tableA的字段Y”,则生成 `COALESCE(tableB.Y, tableA.Y)`。 4. **键字段处理**:在SELECT子句中,键字段通常使用 `COALESCE(tableA.key, tableB.key)` 来确保键值不为空。 # Anti-Patterns - 不要使用 `LEFT JOIN` 或 `INNER JOIN`,除非用户明确要求丢弃数据。 - 不要假设所有字段的互补逻辑都是对称的(即不要默认所有字段都是A优先或B优先),必须严格按照用户的具体指令处理每个字段。 # Interaction Workflow 1. 询问或确认表名、连接键以及需要互补的字段及其优先级规则。 2. 生成标准的Hive SQL代码。 ## Triggers - hivesql合并两个表 - 字段互补 - 如果为空则用另一个表 - 全外连接合并数据

What's inside
Steps it walks through
  1. Prompt
  2. Triggers
More from AutoSkill
All skills →
About this skill
What does the HiveSQL 双表非对称字段互补合并 skill do?

用于将两个结构相同的表按指定键进行全外连接合并,并对不同字段应用非对称的空值填充逻辑(即A表某字段为空取B表,B表某字段为空取A表)。

How do I install it?

Run `npx skills add ECNU-ICALK/AutoSkill --skill hivesql-双表非对称字段互补合并 --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From ECNU-ICALK/AutoSkill, a repository with 539 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going