GoLand 2020.3 Help

Create and delete

Create a table

  1. In the Database tool window, select a data source and navigate to File | New | Table.

  2. In the Create New Table dialog, specify table settings (columns, keys, indexes, foreign keys).

  3. Click OK.

Delete a table

  • To delete a table, right-click the table and select DROP (Delete ).

    You can set additional options for the code that is generated in the SQL Preview field:

    1. Qualify objects with schema names: adds a schema name to the table name. You can qualify a table when you have two and more tables with identical names in different schemes. This option has the following parameters:

      • Auto: automatically qualifies table names if you have more than two identical table names in different schemes.

      • Never: never qualifies table names.

      • Always: always qualifies table names.

    2. Use IF EXISTS syntax: ensures that the table exists.

    3. Use DROP CASCADE syntax: deletes objects that depend on the table (such as views).

Last modified: 08 March 2021