-
-
Notifications
You must be signed in to change notification settings - Fork 653
ERD plugin manual
This plugin, introduced in SQLiteStudio 4.0.0, enables the application to visualize database schema as entities (tables) and relations (foreign keys). It also allows to edit the schema in the same (visual) manner.
[画像:image]To open ERD editor for certain database, have a database (or any object inside that database) highlighted on the databases list. Then hit the ERD editor button on toolbar:
[画像:image]If you don't have button with this icon on your toolbar, check if you have the ERD plugin loaded into SQLiteStudio (go to Configuration window, then to Plugins section).
This editor is not a full-fledged ERD editor in the strict sense. A complete ERD typically includes additional semantic information, such as relationship cardinality (one-to-one, one-to-many), optionality, and other modeling details.
Here, the diagram provides a simplified, ERD-like view focused on practical schema editing: defining tables and managing relationships (foreign keys) between them in a visual way.
- Hold the
Spacebarand drag with the mouse to pan the diagram freely without selecting any items. - Use the
mouse wheelto zoom in and out. - Press
Tor use the toolbar button, then click on the diagram to create a new table at the selected position. - Press
For use the toolbar button, or click themiddle mouse buttonon a table column and then click on another column to create a foreign key relationship. - Press
Escor click theright mouse buttonto cancel table creation or abort foreign key dragging. - Select a table or a foreign key line to edit its properties in the right-side panel.
- Deselect the table (or click Commit in the side panel toolbar) to apply the side panel changes to the diagram.
- Press
Esc(or click Rollback in the side panel toolbar) to discard the side panel changes. - Press the
Deletekey to remove selected tables (DROP TABLE) or relations (ALTER TABLE). - Double-click a foreign key line to visually change its destination.
- Use
Ctrl+F(Cmd+Fon macOS) to search for a table by its name or by a column name. - Press
F5to discard all pending changes and reload the schema from the current database state. You will be asked for confirmation if there are uncommitted changes.
- Use
Ctrl+Z(Cmd+Zon macOS) to undo the last change in the diagram. - Use
Ctrl+Shift+ZorCtrl+Y(Cmd+Shift+Zon macOS) to redo previously undone changes. - You can review all pending changes by clicking the pending changes counter next to the Commit and Rollback buttons on the toolbar.
- In the Pending Changes review dialog you can use "Show effective changes only" option to see actual changes that will be committed to the database (redundant or mutually cancelling steps are merged or removed from the list). If that option is disabled you will see a full undo/redo list.
- Committing pending changes is an atomic operation — it either succeeds completely or fails without applying any changes.
- All diagram changes remain pending until you explicitly commit or roll them back using the toolbar buttons in the top-left corner of the diagram.
- If the database schema is modified outside of the ERD editor while changes are pending, the commit operation may fail if the external changes are incompatible.
- Use
Ctrl+1,Ctrl+2, andCtrl+3(Cmd+... on macOS) to switch between the three foreign key line styles: straight, curved, and orthogonal. - Your custom arrangement of tables is automatically saved and restored the next time you open the ERD editor for the same database.