Improved Formating for SQL Exports

Small updates to the SQL exporter:

  1. SQL Keywords are now uppercased
  2. Line breaks now occur at more sensible points so that the output is more readable


create table "participations" (
  "user_id" bigint not null,
  "project_id" bigint not null,
  "start_date" datetime not null,
  "team_id" bigint not null,
  "department" varchar(255) not null,
  "employee_id" bigint not null
alter table
  primary key `participations_project_id_user_id_primary`(`project_id`, `user_id`);
alter table
  unique `participations_team_id_user_id_unique`(`team_id`, `user_id`);
alter table
  index `participations_department_employee_id_index`(`department`, `employee_id`)


CREATE TABLE `participations`(
    `user_id` BIGINT NOT NULL,
    `project_id` BIGINT NOT NULL,
    `start_date` DATETIME NOT NULL,
    `team_id` BIGINT NOT NULL,
    `department` VARCHAR(255) NOT NULL,
    `employee_id` BIGINT NOT NULL
    `participations` ADD PRIMARY KEY `participations_project_id_user_id_primary`(`project_id`, `user_id`);
    `participations` ADD UNIQUE `participations_team_id_user_id_unique`(`team_id`, `user_id`);
    `participations` ADD INDEX `participations_department_employee_id_index`(`department`, `employee_id`);

🌂Option to collapse Table Comments

You now have a new option for a more condensed view of your table comments.

Option 1: Collapsed

Some teams prefer to include extensive/longer-form notes for each of their tables. In this case, the collapsed option provides a more compact view in the diagram. The table comment will only show an icon by default which can be expanded on click.

Option 2: Always show

Always show the full table comment, useful if the included notes are usually brief and succinct. This is the default.

You can toggle this preference in file > diagram settings, as shown below:

🍯Sidebar UX improvements

Rearranged a few things in the sidebar to make it easier when creating tables & columns: 

  • Overhauled the table name edit component
  • Removed the drag handler for reordering the tables and columns. Instead, you can now just reorder by dragging anywhere within.
  • Hid secondary actions are in a Dropdown - this newfound 'space' for additional action buttons also paves way for the next upcoming features 👁️‍🗨️
  • Added a new dropdown within the top bar, especially useful for performing the common actions like adding a column or index without having to scroll to the bottom

⏫Lots of little improvements to import script for PostgreSQL

Looked through the logs top issues faced by users when importing, and made lost of improvements to the import script. 


  • Handle Aliases like int2, int4, int8, numeric etc.
  • More instructive error logs for when the import fails


  • Added missing enum data type
  • Parse character varying data type (previously only understood varchar)
  • Differentiate timestamp and time with/without TIME ZONE

🗂️Added more data types for PostgreSQL and SQL Server

Added a few column types that were missing:

- PgSQL:


- SQL Server:


🆕Smarter positioning new tables

Another usability improvement, new tables added will always be positioned within the viewport next to the sidebar. Much easier to view changes as you go about creating your table columns etc.

This works regardless of the current pan/zoom-level of the diagram. Tiny improvement, but I've cursed 🤬 at having to zoom around to find that one new table, more times than I'd like to admit.

🔛Collapsible sidebar

Small usability improvement, you can now hide the sidebar to see more of your schema, especially useful in view-only or presentation mode.

It's the small details 🙂

👐Nicer (card) preview when sharing

Diagrams in DrawSQL gets shared around quite a bit on social channels (e.g. Slack, Twitter and face. Up until now it looks unpolished because of the missing Open Graph meta tags:

Much better now:

It also shows a screenshot preview for public diagrams.

🔎Zoom to Fit

An additional zoom control that let's you easily 'reset' your pan position and zoom level to fit the diagram within your viewport.

👯New clone diagram flow

This is a revamp of the previous 'duplicate diagram' functionality. It now comes with a loading indicator, as well as the ability to clone a diagram across your different teams.

User now also have the ability to clone from any of the public diagrams, to serve as a starting point for creating their next database diagram 👀 - a big hint for what we're cooking up next. Keep an eye on our monthly newsletter to learn more!

Show Previous EntriesShow Previous Entries