generateMySQLMigration() — drizzle-orm Function Reference
Architecture documentation for the generateMySQLMigration() function in api.ts from the drizzle-orm codebase.
Entity Profile
Dependency Diagram
graph TD 3334c70a_3efc_ac6c_11fa_8ac2c3304af4["generateMySQLMigration()"] e668bfef_9125_1ef0_2f94_a0f9605584bd["api.ts"] 3334c70a_3efc_ac6c_11fa_8ac2c3304af4 -->|defined in| e668bfef_9125_1ef0_2f94_a0f9605584bd f3976464_9993_b7cc_1cb7_d8087b203650["squashMysqlScheme()"] 3334c70a_3efc_ac6c_11fa_8ac2c3304af4 -->|calls| f3976464_9993_b7cc_1cb7_d8087b203650 style 3334c70a_3efc_ac6c_11fa_8ac2c3304af4 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
drizzle-kit/src/api.ts lines 384–407
export const generateMySQLMigration = async (
prev: DrizzleMySQLSnapshotJSON,
cur: DrizzleMySQLSnapshotJSON,
) => {
const { applyMysqlSnapshotsDiff } = await import('./snapshotsDiffer');
const validatedPrev = mysqlSchema.parse(prev);
const validatedCur = mysqlSchema.parse(cur);
const squashedPrev = squashMysqlScheme(validatedPrev);
const squashedCur = squashMysqlScheme(validatedCur);
const { sqlStatements } = await applyMysqlSnapshotsDiff(
squashedPrev,
squashedCur,
tablesResolver,
columnsResolver,
mySqlViewsResolver,
validatedPrev,
validatedCur,
);
return sqlStatements;
};
Domain
Subdomains
Defined In
Calls
Source
Frequently Asked Questions
What does generateMySQLMigration() do?
generateMySQLMigration() is a function in the drizzle-orm codebase, defined in drizzle-kit/src/api.ts.
Where is generateMySQLMigration() defined?
generateMySQLMigration() is defined in drizzle-kit/src/api.ts at line 384.
What does generateMySQLMigration() call?
generateMySQLMigration() calls 1 function(s): squashMysqlScheme.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free