Database tool window
View | Tool Windows | Database
This functionality relies on the Database Tools and SQL plugin, which is bundled and enabled in GoLand by default. If the relevant features are not available, make sure that you did not disable the plugin.
Press CtrlAlt0S to open settings and then select Plugins.
Open the Installed tab, find the Database Tools and SQL plugin, and select the checkbox next to the plugin name.
In the Database tool window, you can work with databases and DDL data sources. You can view and modify data structures in your databases and perform other associated tasks.
The available data sources are shown as a tree of data sources, schemas, tables, and so on.

If no data sources are currently defined, use the New command AltInsert to create a data source and connect to a database. For more information about data sources, refer to Data sources topic.
Once GoLand is connected to a database, Database tool window will display the introspected database objects. For more information about database tree viewing options, refer to View Options chapter. For more information about working with database objects in GoLand, refer to the corresponding object topics.
Most of the functions in this window are accessed by using the toolbar icons or context menu commands. Many of the commands have keyboard shortcuts.
tip
If the toolbar is not currently shown, click
Options on the header and select Show Toolbar.
Database tool window displays introspected databases and schemas of your data sources. For a database or schema to be shown in the tree, select it in the schema selector of a data source.
For more information about introspection, refer to Glossary.
To see more schemas under your new data source node, click the N of M button and select the ones you need. GoLand will introspect and show them.

To search for a database object in Database tool window, start typing the object's name. Matching database objects will be highlighted.
To toggle the speed search filter, click
Speed Search Filter. To move between several highlighted items, press 0↑ and 0↓.
For more information about speed search, refer to Speed Search in tool windows.
You can filter database objects and hide the objects you do not need to see. To do this, use either the object filter in data source settings or the tool window item filter.
Object filter in data source settings
For example, you can filter out all tables with names starting with
payment_.To filter database objects, open Data Sources and Drivers dialog ( ShiftEnter) .
On the left pane of the dialog, select the data source in which you want to filter database objects.
In the Schemas tab, navigate to Object filter and enter the pattern. In our example,
table:-payment_.*.
tip
In the Object filter field, press Ctrl0Q for the information about syntax.

Item filter in the tool window view options
In the toolbar, click
View Options and select
Filter.
Select or deselect the items that you want to see or hide.
To confirm the selection, click any area in the Database tool window.

In the Database tool window, select the data source you want to copy.
Press Ctrl0C.
The IDE copies the XML snippet with connection settings.
In the target IDE, open Database tool window.
Press Ctrl0V.
In the Data Sources and Drivers that opens, enter the password in the Password field.
tip
GoLand does not store passwords unless they are provided as a parameter in the JDBC URL for the URL only connection type. For more information about password storage, refer to the Passwords topic.
Click OK to save your new data source and close the dialog.
For more information about copying data sources in XML format, refer to Share data sources between IDE instances.
To group data sources in folders, right-click a data source and select Move to Folder. In the Move to Folder dialog, you can either move the data source to an existing folder or create a new one.
tip
If you already have folders, drag a data source to add it to a folder.
For more information about grouping data sources, refer to Group data sources in folders.

Quick documentation displays information about the item. To view the information, select the item and press Ctrl0Q.

To scroll to a database object in the database tree, place the caret over the object's name in code editor. Then, in Database tool window tool window toolbar, click
Scroll from Editor.
The corresponding nodes will open and the object will be highlighted in the database tree.
You can create a quick table backup before any significant data manipulation. To do this, drag the table to the original schema and create a copy of the table in Import dialog.
For more information about the dialog, refer to Import dialog.
In Database tool window, you can toggle the Speed Search Filter results.
Start typing the name of the database object you want to find.
Click
Speed Search Filter on the toolbar.
By default, non-major objects are grouped in the Database Objects and Server Objects nodes. To toggle this grouping, click
View Options in the toolbar, navigate to View in Groups and click Database and Server Objects.
For more information about view options, refer to the Database topic.
Grouping enabled

Grouping disabled

In the Data Sources and Drivers dialog ( ShiftEnter) , click the circle at the end of the Name field and select the color.
Apply the changes and close the dialog.
For more information about assigning colors to data sources, refer to Assign a color to a data source and Assign a color to query consoles and grids.

In the Database tool window, you can display vertical lines that mark indent levels and help you better understand the hierarchy of the objects in your databases.
Press CtrlAlt0S to open settings and then select Appearance & Behavior | Appearance.
In the Tree Views section, enable the Show indent guides option.
Tree indent guides are enabled

Tree indent guides are disabled

You can view comments and last refresh timestamps for the objects in the database tree.
In the toolbar, click
View Options, navigate to Node Details and select Comments and Schema Refresh Time.
You can right-click the window header and use the context menu to configure its viewing mode, associate the window with a different tool window bar, or resize and hide the window.
You can also use the toolbar buttons:
Item | Shortcut | Description |
|---|---|---|
Automatically sets the focus on the object name in the Database tool window when the editor area is in focus. | ||
CtrlNumPad + | Expand all nodes in the current view. | |
CtrlNumPad - | Collapse all expanded nodes in the current view. | |
ShiftEsc | Hide the tool window . To hide all the tool windows, press CtrlShiftF12. |
Item | Description |
|---|---|
Autoscroll from Editor | Makes the database object, that is opened in the editor, automatically selected in the Database tool window. Disables the |
Show Query Console Toolbar | Display the toolbar in the query console tabs. |
| Opens the input field of the Speed Search in tool windows feature. |
Show Toolbar | Display the toolbar in the Database tool window. |
View Mode | This option lets you control general appearance and behavior of the tool window. For full information, refer to Tool window view modes. |
Move to | To associate the tool window with a different tool window bar, select this command, and then select the destination tool window bar (Top, Left, Bottom or Right). For full information, refer to the Move tool windows chapter. |
Resize | To resize the tool window by moving one of its borders, select this command, and then select the necessary Stretch to option. Note that this command is not available for the floating mode. |
Remove from Sidebar | This command hides the tool window, removes the associated tool window button from the tool window bar, and removes the tool window from the quick access menu ( To open the tool window again (and restore the associated features), use the main menu: View | Tool Windows | <Window Name> or press Alt01. |
Help | This command opens the description of the Project tool window in the GoLand online help. |

New
Create a new data source, query console, or a driver.
Available for: Data sources and their elements.
-
Data Source Properties ShiftEnter
Open the Data Sources and Drivers dialog to manage your data sources and their settings.
Available for: All node types.
Refresh CtrlF5
Update the view of the selected element (that is to synchronize the view of the element with its actual state in the database).
See also, Data Sources and Drivers dialog.
Available for: Data sources and their elements.
Deactivate CtrlF2
Close the database connection for the selected data source or data sources.
Available for: Data sources with active connections and their elements.
-
Jump to Query Console CtrlShiftF10
Open the list of query consoles for the selected data source.
Available for: Data sources and their elements.
Edit Data F4
Open a table view of the object in the data editor. This option works for tables, views, and materialized views.
Available for: Corresponding elements in data sources.
-
DDL Go to DDL Ctrl0B
Open the DDL script of the selected object.
For example, if you press this shortcut on a table's name in the
SELECTstatement, you will see the DDL of this table (theCREATE TABLEstatement).
note
The object references in the generated script are not qualified (for example,
<view_name>instead of<schema_name>.<view_name>). You can view this script, edit it, and submit your changes to the database.For a runnable DDL script that includes
CREATE OR REPLACE, qualified references, and so on, use the SQL Generator.Available for: Corresponding elements in data sources.
Compare Structure Ctrl0D
Compare the structure of two database objects in the Migration dialog. The comparison results are shown in the Diff Viewer.
Available for: Two selected database objects of the same kind.
View Options
Open the list of database object tree viewing options, including the item filter. For more information about the options, refer to the View Options chapter.
Available for: All items.
The view options, generally, define what is shown in the tool window and how. To view or change these options, click View Options on the toolbar.

Filter
Open a list of database objects that you can filter. The list of database objects depends on the selected database. To see a full list of available database objects and their icons, go to Icons for data sources and their elements.
The green dot in the corner of filter icon indicates that the filter is on and some objects are filtered out.
FilteredNot filteredEverything is filtered out except views and tables

Nothing is filtered out

- View in Groups | Data Sources
Displays folders for data sources.
For more information about creating folders, refer to Group data sources in folders chapter.
- View in Groups | Databases and Schemas
Displays folders for databases and schemas.
- View in Groups | Server and Database Objects
Displays folders for server and database objects, Server Objects and Database Objects correspondingly. This setting concerns users, roles, tablespaces, modules, foreign data wrappers, and other rarely used objects.
- View in Groups | Object Elements
This option defines how table elements are shown.
When on, there are separate nodes for columns, indexes, primary and foreign key constraints, and triggers (shown as folders). The elements appear in the corresponding groups.
When off, there is no such grouping and, generally, only columns are shown for tables.
- View in Groups | Schema Objects
Defines how schema elements are shown.
When on, there are separate nodes for tables, views, and stored routines (shown as folders). Tables, views and routines (procedures and functions) are shown as elements of the corresponding groups.
When off, there is no explicit grouping for tables, views, and routines. Tables and views are followed by procedures and functions.
- View in Groups | Separate Procedures and Functions
In Microsoft SQL Server, Oracle, and PostgreSQL, separates procedures and functions into different folders.
- View in Groups | Place Constraints and Similar Objects under Schema
Display nodes for object names that exist in a schema namespace. For example, nodes for keys,
CHECKconstraints, indexes, triggers, rules, and other objects.You can use this option in the following situations:
To find an object inside a schema with the help of a quick search.
To see the columns under the table node. To do this, turn off the Empty Groups.
- View in Groups | Sort Alphabetically
Order database objects alphabetically. When the option is disabled, the natural sort order is applied.
- Show Elements | All Namespaces
Show all databases and schemes even if they are not selected for introspection.
When the All Namespaces option is disabled, the databases that are not selected for introspection do not appear in the Database tool window.
When the All Namespaces option is enabled, the databases that are not selected for introspection are displayed in the Database tool window.
- Show Elements | Empty Groups
If the Schema Objects or Object Elements options are selected, you can select to show or hide the categories that contain no elements.
- Show Elements | Intermediate Nodes
Shows or hides parent nodes only when you do not have other objects on the same level with a parent.
- Show Elements | Generated Objects
For Oracle, shows or hides auto-generated objects in the tree. It concerns the following objects:
Materialized view logs
The underlying tables for materialized views
Secondary tables
- Show Elements | Virtual Objects
Show or hides the following objects:
Virtual foreign keys
Virtual views
Virtual columns
- Node details | Comments
Display comments for database objects.
- Node details | Schema Refresh Time
Display the local date and time of the last performed introspection for schemas.
The feature is currently not supported for ClickHouse, Redis, Apache Cassandra, and Apache Hive.
Context-menu actions appear when you right-click an object in the Database tool window.
-
Properties ShiftEnter
Open the Data Sources and Drivers dialog to manage your data sources and their settings.
Available for: Data source and DDL data source nodes.
New
Create a new data source, role, database, schema, query console, table, column, index, a primary, or a foreign key. The list of options depends on which element is currently selected.
Available for: Data sources and their elements.
- Copy/Paste | Copy Data Source Ctrl0C
Copy the XML code snippet with connection settings to the clipboard.
Available for: Data source nodes.
- Copy/Paste | Copy Reference CtrlAltShift0C
Copy the fully qualified name of the selected item to the clipboard.
Available for: Data sources and their elements.
- Copy/Paste | Duplicate Ctrl0D
Create a copy of the selected data source. Specify the properties of the data source in the Data Sources and Drivers dialog that opens.
Available for: Data source and DDL data source nodes.
Edit Data F4
Open a table view of the object in the data editor. This option works for tables, views, and materialized views.
Available for: Corresponding elements in data sources.
- Move to Folder F6
Move the selected data source to a folder. If no folders exist yet, create the first one in the Move to Folder popup that appears.
For more information about grouping data sources, refer to Group data sources in folders.
Available for: Data source and DDL data source nodes.
Refresh CtrlF5
Update the view of the selected element (that is to synchronize the view of the element with its actual state in the database).
See also, Data Sources and Drivers dialog.
Available for: Data sources and their elements.
Deactivate CtrlF2
Close the database connection for the selected data source or data sources.
Available for: Data sources with active connections and their elements.
- Quick Documentation Ctrl0Q
View basic information about the selected element.
To close the documentation popup, press Esc.
Available for: Data sources and their elements.
For more information about quick documentation, refer to quick documentation.
Compare Structure With Ctrl0D
Compare the structure of two database objects in the Migration dialog. The comparison results are shown in the Diff Viewer.
Available for: Two selected database objects of the same kind.
- Navigation | Go to DDL Ctrl0B
Open the DDL script of the selected object.
For example, if you press this shortcut on a table's name in the
SELECTstatement, you will see the DDL of this table (theCREATE TABLEstatement).
note
The object references in the generated script are not qualified (for example,
<view_name>instead of<schema_name>.<view_name>). You can view this script, edit it, and submit your changes to the database.For a runnable DDL script that includes
CREATE OR REPLACE, qualified references, and so on, use the SQL Generator.Available for: Corresponding elements in data sources.
- Navigation | Jump to Query Console CtrlShiftF10
Open the list of query consoles for the selected data source.
Available for: Data sources and their elements.
Run Function or Run Procedure
Run the selected function or procedure.
Available for: Data source elements: functions, procedures.
- Introspection Level
Change the introspection level either for the whole database or for a particular schema. Children inherit a level that is set for a parent.
Available for: Data Source nodes.
- SQL Scripts | SQL Generator CtrlAlt0G
Generate data definition structures for database objects. For example, you can generate DDL files for a single table or for all the tables in the schema. Also, you can customize generation settings. For example, you can set what syntax to use for table creation:
CREATE TABLEorCREATE TABLE IF NOT EXISTS.Available for: Data source elements.
For more information about using SQL Generator, refer to the Generate DDL definitions for database objects and Change output settings of the SQL Generator chapters.
- SQL Scripts | Request and Copy Original DDL
Requests the DBMS server to get or generate a source text for this object, receives this text, and puts it to the clipboard.
Available for: Data sources and their elements.
- SQL Scripts | Generate DDL to Clipboard CtrlAltShift0G
Generate a DDL of the object and copy it to the clipboard.
Available for: Data sources and their elements.
- SQL Scripts | Generate DDL to Query Console CtrlAltShift0B
Generate a DDL of the object and copy it to the query console.
Available for: Data sources and their elements.
- Object Actions | Rename ShiftF6
Rename the selected item. Specify the new name in the dialog that opens.
Available for: Data sources and their elements.
- Object Actions | Enable triggers/constraints
Enable triggers and constraints for the selected table.
Available for: Data source elements: tables.
- Object Actions | Disable triggers/constraints
Disable triggers and constraints for the selected table.
Available for: Data source elements: tables.
- Object Actions | Modify Comment
Modify the database object comment in the Modify Comment dialog.
- Object Actions | Modify Grants
Modify the grants of a database object in the Modify Grants of <object_name> dialog.
- Object Actions | Truncate…
Remove all the rows in the selected table.
Available for: Data source elements: tables.
- Object Actions | Drop or Object Actions | Remove Data Source Delete
Remove the selected item.
Available for: Data sources and their elements.
- Tools | Manage Shown Schemas
Open a popup with available schemas for the current data source.
See also, Show and hide schemas.
Available for: Data sources and their elements.
- Tools | Full-text Search ShiftCtrlAlt0F
Search for data in your databases or a group of databases without knowing the data's exact location.
Available for: Data sources and their elements.
For more information about the full-text search, refer to Full-text search in databases.
- Tools | Set Color
Open the Database Color Settings dialog to set or change the color for the selected element or elements.
See also, Assign a color to query consoles and grids.
Available for: Data sources and their elements.
- Tools | Add Bookmark F11
Add the selected item to bookmarks.
Available for: Data sources and their elements.
- Tools | Scripted Extensions | Generate POJOs.clj
Generate a Java entity class for the selected table. In the dialog that opens, specify the directory in which the JAVA class file should be generated.
Available for: Data sources and their elements.
- Tools | Scripted Extensions | Go To Scripts Directory
Switch to the directory where theGenerate POJOs.cljexample script file is located.
Available for: Data sources and their elements.
- Import/Export | Export Data to File
Save data for the selected tables and views in files. Select the output format (for example, SQL Inserts, Tab-separated (TSV), JSON-Clojure.json.clj).
Available for: Data source elements: tables and views.
- Import/Export | Import Data from File(s)…
Import a text file containing delimiter-separated values (CSV, TSV, and so on) into your database.
If a schema is currently selected, GoLand will create a new table for the data that you are importing. If a table is selected, GoLand will try to add the data to the selected table.
Available for: Database tables.
- Import/Export | Copy Table to F5
Create a copy of the selected table. You can create a copy in a different scheme or data source. For example, you can copy the
actortable from MySQL to PostgreSQL.Available for: Database tables and views.
- Import/Export | Dump to DDL Data Source
Create your DDL data source by dumping a regular data source to a root/repository folder.
Available for: Data sources and their elements.
- Import/Export | Export with 'mysqldump' or Import/Export | Export with 'pg_dump'
Run mysqldump or pg_dump for the selected items. mysqldump and pg_dump are native MySQL and PostgreSQL tools. They are not integrated into GoLand. You can read about them at dev.mysql.com and postgresql.org.
Available for: Data source nodes.
- Import/Export | Restore with 'mysql' or Import/Export | Restore with 'psql' or Restore
Run mysql, pg_restore, or psql to restore a data dump. These tools are native for MySQL and PostgreSQL. They are not integrated into GoLand. You can read about them at dev.mysql.com and postgresql.org.
Available for: Data source nodes.
- Diagrams | Show Diagram CtrlAltShift0U
View a UML class diagram for the selected data source or table in a separate editor tab.
Available for: Data sources and their elements.
- Diagrams | Show Diagram Popup CtrlAlt0U
View a UML class diagram for the selected data source or table in a popup.
Available for: Data sources and their elements.
- Diagnostics | Dump Metadata Model
Generate a diagnostic representation of the database in a GoLand internal format. This information might be helpful for the support team if some database objects exist in the database but do not show up in the Database tool window.
Available for: Data sources and their elements.
- Diagnostics | Generate Introspector Diagnostic Files
Generate three files that include information about the following:
dataSource.txt: the data source.
introspector.txt: a module that was used to load the metadata from the database.
model.xml: a part of the database model.
This information is helpful when introspection works incorrectly.
Available for: Data sources and their elements.
- Diagnostics | Show JDBC Log Settings
Open the JDBC Log Setting dialog to configure the JDBC driver log settings.
Available for: Data sources and their elements.
- Diagnostics | Force Refresh CtrlShiftF5
Delete the data source information from cache and load it again. This action is available on the data source node only.
Available for: Data source nodes.
- Diagnostics | Forget This Schema Cache
Delete the information that GoLand has accumulated about your database. This action is available on the data source node only.
Use this command when you experience issues like wrong display of data structures or errors during synchronization.
To check if this has eliminated the problem, use the Synchronize command.
Available for: Data source nodes.
- Diagnostics | Diagnostic Mode
Enables the diagnostic mode where GoLand writes the introspection log.
You can access the log file by clicking the link in the Diagnostic log started and Diagnostic log stopped notification popups that appear once you enable and disable the mode.

Icon | Description |
|---|---|
Access Method | |
Aggregate | |
Alias Type | |
Argument | |
Body | |
Check | |
Cluster | |
Collation | |
Collection Type | |
Column. For more information about column icon combinations, refer to Possible icon combinations for columns. | |
Data File | |
Database | |
Read-only status | |
DDL data source | |
Default | |
Exception | |
Extension | |
External Schema | |
Foreign Data Wrapper | |
Foreign Key | |
Foreign Table | |
Index | |
Key | |
Materialized Log | |
Materialized View | |
Object Attribute | |
Object Type | |
Operator | |
Package | |
Primary key | |
Projection | |
Data sources | |
Role | |
Routine | |
Rule | |
Scheduled Event | |
Schema | |
Sequence | |
Server | |
Stored procedure or function | |
Synonym | |
Table | |
Table Type | |
Tablespace | |
Trigger | |
User | |
User Mapping | |
Variable | |
View | |
Virtual column | |
Virtual foreign key | |
Virtual view | |
Virtual Table |
Icon | Foreign key | Primary key | Indexed | NOT NULL |
|---|---|---|---|---|
Thanks for your feedback!