Import: SQL, DBML & Projects | ERD Generator Docs
Easily bring your existing database schemas into the ERD Generator.
Whether you already have SQL scripts, DBML files, or a saved project, importing lets you instantly visualize, explore, and improve your database design.
This feature is designed for speed, accuracy, and zero setup β just import and start working.
π What You Can Import
You can import schemas from multiple sources and formats:
π§© SQL Databases
Import raw SQL schema files from popular databases:
- MySQL
- PostgreSQL
- Microsoft SQL Server
- Legacy PostgreSQL
- Legacy SQL Server
Perfect for existing production databases or migration projects.
π DBML Files
Already using DBML?
Upload your .dbml files directly and continue editing or visualizing them without any conversion steps.
DBML imports preserve:
- Tables and columns
- Relationships
- Primary & foreign keys
- Notes and descriptions
π¦ Saved Projects
Reopen previously saved ERD Generator projects to continue exactly where you left off.
Ideal for:
- Long-running designs
- Team collaboration
- Iterative schema refinement
π What Happens After Import?
No matter what you import, everything is automatically converted into DBML internally.
This means:
- A single, consistent format
- Easier editing and visualization
- Reliable diagram generation
- Seamless export to SQL or DBML later
You donβt need to worry about formats β the tool handles it for you.
π§ Step-by-Step: How to Import
- Open the Import dialog
- Choose the source:
- SQL
- DBML
- Project
- Select the database type (if importing SQL)
- Upload your file or paste your schema
- Click Import
Thatβs it β your diagram is ready instantly.
βοΈ Import Options Explained
Database Dialect Selection
When importing SQL, choose the correct dialect to ensure accurate parsing:
- MySQL
- PostgreSQL
- SQL Server
- Legacy variants (for older schemas)
This ensures:
- Correct data types
- Accurate constraints
- Proper relationships
Metadata Handling
During import, you can choose how much detail to include:
- Table comments
- Column notes
- Indexes
- Constraints
Include everything for full documentation, or keep it minimal for clean diagrams.
π§ Best Practices for Clean Imports
- Use schema-only SQL when possible (DDL, not data)
- Ensure foreign keys are defined for best relationship detection
- Choose the correct database type before importing
- For large schemas, import once and refine visually
π Common Use Cases
- Reverse-engineer an existing database
- Migrate schemas between databases
- Visualize legacy systems
- Review and refactor complex schemas
- Generate ER diagrams for documentation or onboarding
β Troubleshooting Tips
Tables not connected?
β Ensure foreign keys exist in your SQL.
Unexpected column types?
β Double-check the selected database dialect.
Large schema feels cluttered?
β Use layout options and diagram customization after import.
π Safe & Private
- Imports happen entirely in your workspace
- No schema data is shared or exposed
- Ideal for private and production databases
β Why Import Instead of Rebuild?
- Saves hours of manual work
- Eliminates human error
- Ensures accuracy with real schemas
- Instantly creates a visual understanding of your database
π― Next Steps
After importing, you can:
- Customize the diagram layout
- Edit DBML directly
- Export to SQL or DBML
- Share diagrams with your team
Start by importing β everything else builds on top of it.