type-mapping-encyclopedia
RDBMS-to-RDBMS data type mapping tables, RDBMS-to-NoSQL conversion patterns, character set/collation conversion, and special type handling guide. Use this skill for requests involving 'type mapping', 'data type conversion', 'MySQL PostgreSQL conversion', 'Oracle migration', 'character set conversion', 'collation', 'AUTO_INCREMENT sequence', 'JSON type', etc. Enhances schema-mapper's type conversion capabilities. Note: ETL script writing and validation queries are outside the scope of this skill.
Best use case
type-mapping-encyclopedia is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
RDBMS-to-RDBMS data type mapping tables, RDBMS-to-NoSQL conversion patterns, character set/collation conversion, and special type handling guide. Use this skill for requests involving 'type mapping', 'data type conversion', 'MySQL PostgreSQL conversion', 'Oracle migration', 'character set conversion', 'collation', 'AUTO_INCREMENT sequence', 'JSON type', etc. Enhances schema-mapper's type conversion capabilities. Note: ETL script writing and validation queries are outside the scope of this skill.
Teams using type-mapping-encyclopedia should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/type-mapping-encyclopedia/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How type-mapping-encyclopedia Compares
| Feature / Agent | type-mapping-encyclopedia | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
RDBMS-to-RDBMS data type mapping tables, RDBMS-to-NoSQL conversion patterns, character set/collation conversion, and special type handling guide. Use this skill for requests involving 'type mapping', 'data type conversion', 'MySQL PostgreSQL conversion', 'Oracle migration', 'character set conversion', 'collation', 'AUTO_INCREMENT sequence', 'JSON type', etc. Enhances schema-mapper's type conversion capabilities. Note: ETL script writing and validation queries are outside the scope of this skill.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
# Type Mapping Encyclopedia — Data Type Mapping Reference
A comprehensive reference for RDBMS-to-RDBMS data type mapping, special type conversions, and character set handling.
## MySQL to PostgreSQL Mapping
| MySQL | PostgreSQL | Notes |
|-------|-----------|-------|
| TINYINT | SMALLINT | TINYINT UNSIGNED -> SMALLINT |
| INT | INTEGER | |
| INT UNSIGNED | BIGINT | PostgreSQL has no UNSIGNED |
| BIGINT | BIGINT | |
| FLOAT | REAL | |
| DOUBLE | DOUBLE PRECISION | |
| DECIMAL(M,N) | NUMERIC(M,N) | Identical |
| VARCHAR(N) | VARCHAR(N) | |
| CHAR(N) | CHAR(N) | |
| TEXT | TEXT | |
| MEDIUMTEXT | TEXT | PostgreSQL TEXT has no size limit |
| LONGTEXT | TEXT | |
| BLOB | BYTEA | |
| LONGBLOB | BYTEA | Or use Large Object |
| DATE | DATE | |
| DATETIME | TIMESTAMP | MySQL: not UTC; PG: timezone option |
| TIMESTAMP | TIMESTAMPTZ | MySQL: auto UTC conversion |
| TIME | TIME | |
| YEAR | SMALLINT | |
| ENUM('a','b') | VARCHAR + CHECK | Or CREATE TYPE |
| SET('a','b') | VARCHAR[] | Or normalize |
| JSON | JSONB | JSONB recommended (indexable) |
| BIT(N) | BIT(N) | |
| BOOLEAN | BOOLEAN | MySQL TINYINT(1) -> BOOLEAN |
| AUTO_INCREMENT | GENERATED ALWAYS AS IDENTITY | Or SERIAL (legacy) |
### Special Conversion Patterns
```sql
-- MySQL ENUM -> PostgreSQL
-- Method 1: CHECK constraint
CREATE TABLE orders (
status VARCHAR(20) CHECK (status IN ('pending', 'paid', 'shipped'))
);
-- Method 2: Custom type
CREATE TYPE order_status AS ENUM ('pending', 'paid', 'shipped');
CREATE TABLE orders (status order_status);
-- MySQL AUTO_INCREMENT -> PostgreSQL IDENTITY
-- MySQL:
CREATE TABLE users (id INT AUTO_INCREMENT PRIMARY KEY);
-- PostgreSQL:
CREATE TABLE users (id INTEGER GENERATED ALWAYS AS IDENTITY PRIMARY KEY);
-- MySQL ON UPDATE CURRENT_TIMESTAMP -> PostgreSQL trigger
CREATE OR REPLACE FUNCTION update_modified_column()
RETURNS TRIGGER AS $$
BEGIN NEW.updated_at = CURRENT_TIMESTAMP; RETURN NEW; END;
$$ LANGUAGE plpgsql;
CREATE TRIGGER update_timestamp BEFORE UPDATE ON users
FOR EACH ROW EXECUTE FUNCTION update_modified_column();
```
## Oracle to PostgreSQL Mapping
| Oracle | PostgreSQL | Notes |
|--------|-----------|-------|
| NUMBER | NUMERIC | Precision specification required |
| NUMBER(N,0) | INTEGER/BIGINT | Choose based on size |
| VARCHAR2(N) | VARCHAR(N) | |
| CHAR(N) | CHAR(N) | |
| CLOB | TEXT | |
| BLOB | BYTEA | |
| DATE | TIMESTAMP | Oracle DATE includes time! |
| TIMESTAMP WITH TIME ZONE | TIMESTAMPTZ | |
| RAW | BYTEA | |
| LONG | TEXT | Deprecated — migration recommended |
| NVARCHAR2 | VARCHAR | PostgreSQL defaults to UTF-8 |
| ROWID | N/A | Use ctid or custom key |
| SEQUENCE | SEQUENCE | Similar syntax |
| SYSDATE | CURRENT_TIMESTAMP | |
| NVL() | COALESCE() | |
| DECODE() | CASE WHEN | |
## RDBMS to MongoDB Conversion Patterns
### Denormalization Strategy
```
Relational: Document:
+- users -+ +- orders -+ {
| id | | id | _id: ObjectId,
| name | | user_id |-> name: "John Doe",
| email | | total | email: "john@test.com",
+----------+ | items[] | orders: [
+----------+ { total: 50000,
items: [
{ product: "A", qty: 2 }
]
}
]
}
```
### Embedding vs. Reference Decision
| Criterion | Embedding (Nested) | Reference (Separate) |
|-----------|-------------------|---------------------|
| Relationship | 1:1, 1:Few | 1:Many, M:N |
| Read pattern | Always queried together | Frequently queried independently |
| Update frequency | Updated with parent | Updated independently |
| Data size | < 16MB (document limit) | Size independent |
| Duplication | Acceptable | Deduplication required |
## Character Set / Collation Conversion
### MySQL to PostgreSQL
```sql
-- MySQL character set check
SHOW VARIABLES LIKE 'character_set%';
SELECT character_set_name, collation_name
FROM information_schema.columns WHERE table_name = 'users';
-- PostgreSQL collation
-- MySQL utf8mb4_general_ci -> PostgreSQL ICU collation
CREATE COLLATION korean_ci (
provider = icu, locale = 'ko-u-ks-level1', deterministic = false
);
-- Case-insensitive comparison
-- MySQL: utf8mb4_general_ci (default)
-- PostgreSQL: citext extension or LOWER() index
CREATE EXTENSION IF NOT EXISTS citext;
ALTER TABLE users ALTER COLUMN email TYPE citext;
```
### Encoding Conversion Notes
| Issue | Symptom | Solution |
|-------|---------|----------|
| MySQL utf8 (3-byte) | Emojis break | Convert to utf8mb4 before migration |
| Latin1 to UTF8 | CJK characters corrupted | Route through binary intermediate step |
| EUC-KR to UTF8 | Rare CJK characters lost | Use mapping tables |
| CP949 to UTF8 | Extended characters need verification | Pre-validate with iconv |
## Irreversible Conversion Inventory
| Conversion | Reason for Irreversibility | Mitigation |
|-----------|--------------------------|-----------|
| ENUM -> VARCHAR | Allowed value constraint lost | Add CHECK constraint |
| UNSIGNED INT -> INT | Negative range expanded | Reinforce with business rules |
| DATETIME -> TIMESTAMPTZ | Timezone info must be added | Explicitly state assumed TZ |
| ROWID -> ctid | Physical location dependent | Replace with logical key |
| Oracle DATE -> PG DATE | Time portion lost | Use TIMESTAMP instead |
| CLOB -> TEXT | Behavior is identical | -- |
## Type Mapping Verification Queries
```sql
-- Source (MySQL)
SELECT column_name, data_type, column_type,
character_maximum_length, numeric_precision, numeric_scale,
is_nullable, column_default, extra
FROM information_schema.columns
WHERE table_schema = 'mydb' AND table_name = 'orders'
ORDER BY ordinal_position;
-- Target (PostgreSQL)
SELECT column_name, data_type, udt_name,
character_maximum_length, numeric_precision, numeric_scale,
is_nullable, column_default
FROM information_schema.columns
WHERE table_schema = 'public' AND table_name = 'orders'
ORDER BY ordinal_position;
```Related Skills
stakeholder-mapping
crisis stakeholder mapping framework. situation-analyst and message-strategist agent crisis when stakeholderby response strategy establishto do when reference. 'stakeholder analysis', 'crisis etc.grade', 'impact assessment' request when usage. However, rate specialistdocument versus scope outside.
process-mapping
process mapping method. process-analyst agent work flow analysisand visualizationto do when reference mapping technique and tabletechnique. 'SIPOC', 'process map', 'Value Stream Map' request when usage. However, BPM whensystem building specialist development scope outside.
ddd-context-mapping
Detailed methodology for DDD (Domain-Driven Design) bounded context identification, context map creation, and event storming execution. Use this skill for 'bounded context', 'DDD', 'domain modeling', 'event storming', 'context map', 'aggregate design', 'ubiquitous language', and other domain analysis tasks. Enhances the domain analysis capabilities of domain-analyst and service-architect. Note: infrastructure deployment and code implementation are outside the scope of this skill.
brand-archetype
A brand archetype skill used by the brand-strategist and copywriter agents. Provides Jungian 12-archetype-based brand personality design, tone-and-voice mapping, and storytelling frameworks. Used for 'brand personality,' 'archetypes,' 'tone and voice,' 'brand story,' and related topics.
sustainability-audit
Full audit pipeline for ESG/sustainability where an agent team collaborates to generate environmental, social, and governance assessments along with an integrated report and improvement plan. Use this skill for requests such as 'run an ESG audit', 'write a sustainability report', 'ESG assessment', 'carbon emissions calculation', 'ESG rating diagnosis', 'governance review', 'social responsibility assessment', 'GRI report', 'TCFD disclosure', 'ESG improvement plan', and other ESG/sustainability tasks. Also supports assessment of specific pillars (E/S/G) only or improving existing reports. However, actual on-site audit execution, third-party verification certificate issuance, ESG rating agency score changes, and carbon credit trading are outside the scope of this skill.
materiality-assessment
ESG materiality assessment matrix. Referenced by the esg-reporter and improvement-planner agents when evaluating ESG issue materiality and setting priorities. Use for 'materiality assessment', 'importance analysis', or 'Materiality Matrix' requests. Stakeholder surveys and external certification are out of scope.
ghg-protocol
GHG Protocol detailed guide. Referenced by the environmental-analyst agent when calculating and reporting greenhouse gas emissions. Use for 'GHG Protocol', 'carbon emissions', 'Scope 1/2/3', or 'carbon footprint' requests. Carbon credit trading and CDM project execution are out of scope.
citation-standards
Academic citation and reference standards guide. Referenced by the paper-writer and submission-preparer agents when composing citations and references. Use for 'citation format', 'APA', or 'references' requests. Original paper retrieval and professional database access are out of scope.
academic-paper
Full research pipeline for academic paper writing where an agent team collaborates to generate research design, experiment protocols, analysis, manuscript writing, and submission preparation. Use this skill for requests such as 'write an academic paper', 'research paper writing', 'help me write a paper', 'design a study', 'run statistical analysis', 'prepare journal submission', 'manuscript writing', 'research methodology design', 'hypothesis testing', 'academic writing', and other academic research paper tasks. Also supports analysis, rewriting, and submission preparation when existing data or drafts are available. However, actual data collection execution, official IRB submission, journal system login and upload, and running actual statistical software are outside the scope of this skill.
product-copy-formulas
Product copy formula library. Referenced by the detail-page-writer and marketing-manager agents when writing purchase-driving copy. Use for 'product copy', 'marketing copy', or 'ad copy' requests. Ad placement and design mockup creation are out of scope.
ecommerce-launcher
Full launch pipeline for e-commerce products where an agent team collaborates to generate product planning, detail pages, pricing strategy, marketing, and CS setup all at once. Use this skill for requests such as 'launch an e-commerce product', 'prepare a product launch', 'register a product on Naver Smart Store', 'launch on Coupang', 'create a detail page', 'develop a pricing strategy', 'create a marketing plan', 'launch prep', 'product planning brief', 'e-commerce CS manual', and other e-commerce product launch tasks. Also supports supplementing pricing/marketing/CS even when existing briefs or detail pages are provided. However, actual platform API integration (automated product registration), payment system development, logistics system integration, and real-time order management are outside the scope of this skill.
conversion-optimization
Purchase conversion optimization framework. Referenced by the detail-page-writer and pricing-strategist agents when designing detail pages and pricing with a conversion focus. Use for 'conversion rate optimization', 'CRO', or 'purchase psychology' requests. A/B testing tool setup and funnel automation are out of scope.