Context menu commands and shortcuts
|New||Alt+InsertAlt+Insert||Use this command to create a new data source, table, table column, index, or primary or foreign key.
The list of options depends on which element is currently selected.
If a data source is selected, or if there are no data sources currently defined and nothing is selected, you can choose:
If a table in a DB data source is selected, you can choose:
If a table column or a number of columns in a DB data sources is selected, you can choose:
|DB data sources and their elements (tables and table columns). If a DDL data source is selected, you can only choose to create another data source.|
|Close Connection||DeleteDelete||Use this command to close the selected active database connection (shown as underneath the corresponding DB data source node).||Active connections|
Use this command to remove constraints such as a primary key or a foreign key constraint.
||Tables and table columns in DB data sources|
|Rename||Shift+F6Shift+F6||Use this command to rename the selected data source, table or table column. Specify the new name in the dialog that opens.||All node types except active connections|
|Duplicate||Ctrl+DCtrl+D||Use this command to create a copy of the selected data source. Specify the properties of the data source in the Data Source Properties dialog that opens. See DB Data Source Properties or DDL Data Source Properties.||DB and DDL data source nodes|
|Modify Column||Ctrl+F6Ctrl+F6||Use this command to edit the properties of the selected column.||Table columns in DB data sources|
|Copy Reference||Ctrl+Alt+Shift+CCtrl+Alt+Shift+C||Use this command to copy the fully qualified name of the selected data source, table or table column to the clipboard.||All node types except active connections|
|Delete||DeleteDelete||Use this command to delete the selected data source, table or table column.||All node types except active connections|
|Find Usages||Alt+F7Alt+F7||Use this command to find the usages of (references to) the selected item (data source, table or table column) in the project source files and libraries.||All node types except active connections|
|Compare||Ctrl+DCtrl+D||Select two data sources or tables and then use this command to compare the selected items. The differences are shown in Differences Viewer for Folders and DB Objects.||DB and DDL data sources and tables|
|Table Editor||F4F4||Use this command to open the selected database table in the Table Editor.
See also, Manipulating Table Data in the Table Editor.
|Tables and table columns in DB data sources|
Procedure Editor or
|F4F4||Use this command to open the definition of the selected view, function, procedure or package in the editor.||Corresponding elements in DB data sources|
|Edit Source||F4F4||Use this command to open the associated DDL file in the editor.||Tables and table columns in DDL data sources|
|Console||Ctrl+Shift+F10Ctrl+Shift+F10||Use this command to open the database console for the corresponding DB data source. As a result, you'll be able to run DDL and DML SQL statements to manipulate data structures and data.||DB data sources and their elements (tables and table columns)|
|Synchronize||Ctrl+Alt+YCtrl+Alt+Y||Use this command to update the view of the selected element (i.e. to synchronize the view of the element with its actual state in the database).||DB data sources and their elements (tables and table columns)|
|Properties||EnterEnter||Use this command to view or edit the properties of the selected data source in the Data Source Properties dialog. See DB Data Source Properties or DDL Data Source Properties.||DB and DDL data source nodes|
|Copy DDL||Ctrl+Shift+CCtrl+Shift+C||Use this command to copy a DDL definition of the selected data source, table or table column onto the clipboard.||All node types except active connections|
|Save to File||Use this command to save the selected table in a file, or to view or edit the export settings.
||Tables in DB data sources|
|Use this command to see a UML class diagram for the selected data source or table. Select:
||DB and DDL data sources and tables|
Use this key combination to see basic information for the selected element.
The information shown depends on the element type.
For example, the following is shown for a table: the names of the data source, catalog, schema and the table itself.
Also shown is the corresponding CREATE TABLE DDL statement and, if appropriate, the first 10 table rows.
To close the documentation pop-up, press EscapeEscape.
|All node types except active connections|
Icons for data sources and their elements
|DB data source|
Database connection for a DB data source (appears right underneath the corresponding data source node as soon as the connection is established).
PyCharm establishes a database connection automatically first time it needs to execute a query, and closes it automatically upon the session end. If necessary, a connection can be terminated manually, using the context menu command Close Connection.
|DDL data source|
|A NOT NULL column|
|Column with a primary key|
|Column with a foreign key|
|Column with an index|
|Stored procedure or function|