Compute
Elastic Cloud Server
Huawei Cloud Flexus
Bare Metal Server
Auto Scaling
Image Management Service
Dedicated Host
FunctionGraph
Cloud Phone Host
Huawei Cloud EulerOS
Networking
Virtual Private Cloud
Elastic IP
Elastic Load Balance
NAT Gateway
Direct Connect
Virtual Private Network
VPC Endpoint
Cloud Connect
Enterprise Router
Enterprise Switch
Global Accelerator
Management & Governance
Cloud Eye
Identity and Access Management
Cloud Trace Service
Resource Formation Service
Tag Management Service
Log Tank Service
Config
OneAccess
Resource Access Manager
Simple Message Notification
Application Performance Management
Application Operations Management
Organizations
Optimization Advisor
IAM Identity Center
Cloud Operations Center
Resource Governance Center
Migration
Server Migration Service
Object Storage Migration Service
Cloud Data Migration
Migration Center
Cloud Ecosystem
KooGallery
Partner Center
User Support
My Account
Billing Center
Cost Center
Resource Center
Enterprise Management
Service Tickets
HUAWEI CLOUD (International) FAQs
ICP Filing
Support Plans
My Credentials
Customer Operation Capabilities
Partner Support Plans
Professional Services
Analytics
MapReduce Service
Data Lake Insight
CloudTable Service
Cloud Search Service
Data Lake Visualization
Data Ingestion Service
GaussDB(DWS)
DataArts Studio
Data Lake Factory
DataArts Lake Formation
IoT
IoT Device Access
Others
Product Pricing Details
System Permissions
Console Quick Start
Common FAQs
Instructions for Associating with a HUAWEI CLOUD Partner
Message Center
Security & Compliance
Security Technologies and Applications
Web Application Firewall
Host Security Service
Cloud Firewall
SecMaster
Anti-DDoS Service
Data Encryption Workshop
Database Security Service
Cloud Bastion Host
Data Security Center
Cloud Certificate Manager
Edge Security
Managed Threat Detection
Blockchain
Blockchain Service
Web3 Node Engine Service
Media Services
Media Processing Center
Video On Demand
Live
SparkRTC
MetaStudio
Storage
Object Storage Service
Elastic Volume Service
Cloud Backup and Recovery
Storage Disaster Recovery Service
Scalable File Service Turbo
Scalable File Service
Volume Backup Service
Cloud Server Backup Service
Data Express Service
Dedicated Distributed Storage Service
Containers
Cloud Container Engine
SoftWare Repository for Container
Application Service Mesh
Ubiquitous Cloud Native Service
Cloud Container Instance
Databases
Relational Database Service
Document Database Service
Data Admin Service
Data Replication Service
GeminiDB
GaussDB
Distributed Database Middleware
Database and Application Migration UGO
TaurusDB
Middleware
Distributed Cache Service
API Gateway
Distributed Message Service for Kafka
Distributed Message Service for RabbitMQ
Distributed Message Service for RocketMQ
Cloud Service Engine
Multi-Site High Availability Service
EventGrid
Dedicated Cloud
Dedicated Computing Cluster
Business Applications
Workspace
ROMA Connect
Message & SMS
Domain Name Service
Edge Data Center Management
Meeting
AI
Face Recognition Service
Graph Engine Service
Content Moderation
Image Recognition
Optical Character Recognition
ModelArts
ImageSearch
Conversational Bot Service
Speech Interaction Service
Huawei HiLens
Video Intelligent Analysis Service
Developer Tools
SDK Developer Guide
API Request Signing Guide
Terraform
Koo Command Line Interface
Content Delivery & Edge Computing
Content Delivery Network
Intelligent EdgeFabric
CloudPond
Intelligent EdgeCloud
Solutions
SAP Cloud
High Performance Computing
Developer Services
ServiceStage
CodeArts
CodeArts PerfTest
CodeArts Req
CodeArts Pipeline
CodeArts Build
CodeArts Deploy
CodeArts Artifact
CodeArts TestPlan
CodeArts Check
CodeArts Repo
Cloud Application Engine
MacroVerse aPaaS
KooMessage
KooPhone
KooDrive
On this page

Adding a Connection

Updated on 2023-03-17 GMT+08:00

Perform the following steps to create a database connection.

  1. Choose File > New Connection from the main menu.

    Alternatively, click on the toolbar, or press Ctrl+N to connect to the database. The New Database Connection dialog box is displayed.

    NOTE:

    If the preference file is damaged or the preference settings are invalid during connection creation, an error message will be displayed indicating that the preferred value is invalid and prompting you to restore the default preference settings. Click OK to complete the operation of creating a database connection.

  2. The table in the left of the dialog box lists the details of existing connections and server information.

    NOTE:

    The server information will be displayed only after the connection succeeds.

    • You can populate connection parameters, such as Connection Name, Host, and Host Port, by double-clicking the connection name.
    NOTE:

    If the password or key for any of the existing connections is damaged, you need to enter the password for whichever connection you use.

    • If you click , different pop-up messages based on the connection statuses of database will be displayed.
      • If the database connection is active, the Remove Connection Confirmation dialog box is displayed. Click Yes to disconnect all databases.
      • If the database connection is not active, the Remove Connection dialog box is displayed.
    • If you click without selecting a connection name, a dialog box is displayed prompting you to select at least one connection.

  3. Configure the following parameters to create a database connection.

    NOTE:
    • Click Clear to clear all fields in the New Database Connection dialog box.
    • Press Ctrl+V to paste data in the New Database Connection dialog box. Right-click options are not available in the dialog boxes of Data Studio.

    Field Name

    Description

    Example

    Database Type

    Specifies the database type.

    -

    Connection Name

    Specifies the connection name.

    My_Connection_DB

    Host

    Specifies the host IP address (IPv4) or database domain name.

    NOTE:
    • If domain name length is greater than 25 characters, the complete domain name will not be displayed.

      For example, test1(db.dws…com:25xxx) cannot be displayed completely.

    • Once the connection is created, hover the cursor over the connection name to see the server IP and version.
    • The value of this field will be identified as an IP address if it contains only digits with three periods (.). Otherwise, it will be identified as a domain name.
    • A domain name must meet the following requirements:
      • Starts with a letter.
      • Contains only letters, digits, hyphens (-), and periods (.) and cannot contain any other special character.
      • Cannot contain spaces or tabs.
      • Contains 1 to 253 characters and a maximum of 63 characters between periods.

    db.dws.mycloud.com

    10.xx.xx.xx

    Host Port

    Specifies the port address.

    8000

    Database Name

    Specifies the database name.

    gaussdb

    User Name

    Specifies the username for connecting to the selected database.

    -

    Password

    Specifies the password for connecting to the selected database. The password is masked.

    -

    • In the Save Password drop-down list, select one of the following options:
    • The Enable SSL option is selected by default.

  4. Perform the following steps to enable SSL:

    1. Select the Enable SSL option.
    2. Click the SSL tab.

    3. Provide the files listed in SSL Certificates to use secure connections.
      • Click of Client SSL Certificate and select a client SSL certificate.
      • Click of Client SSL Key and select a client SSL key.
      • Click of Root Certificate and select a root certificate.
      • Select an SSL mode from the SSL Mode drop-down list. Refer to table below for description of different SSL modes.
        NOTE:
        • If SSL Mode is set to verify-ca or verify-full, Root Certificate must be selected.
        • Data Studio prompts you to enter the client key upon the first access to the gs_dump feature.

        SSL Mode

        Description

        require

        The certificate will not be verified as the used SSL factory does not need to be verified.

        verify-ca

        The certificate authority (CA) will be verified using the corresponding SSL factory.

        verify-full

        The CA and database will be verified using the corresponding SSL factory.

        NOTE:
        • You can a valid Client SSL Certificate and Client SSL Key to export DDL and data from Data Studio using secure connections.
        • If the selected Client SSL Certificate and Client SSL Key are invalid, the export will fail. For details, see Troubleshooting.
        • If you deselect Enable SSL and proceed, the Connection Security Alert dialog box is displayed. Refer to Security Disclaimer to determine whether to display this dialog box.
          • Continue: continues to use insecure connections
          • Cancel: enables SSL
          • Do not show again: The Connection Security Alert dialog box is not displayed for the subsequent connections of logged Data Studio instances.
        • For details, see the server manual.

  5. Perform the following steps to set Fast Load Options:

    1. Click the Advanced tab.

    2. When creating a connection, enter the schema names separated by commas in the Include field to load these schemas preferentially.
    3. When creating a connection, enter the schema names separated by commas in the Exclude field to avoid loading these schemas preferentially.
    4. Select either of the following options for Load Objects:
      • All objects: loads all objects
      • Objects allowed as per user privilege: loads only objects that the user has permissions for accessing. For details about the minimum permissions for accessing objects listed in Object Browser, see Table 1.
      NOTE:

      The default value is Objects allowed as per user privilege.

    5. Enter the number of database objects that can be loaded in Load Limit. The maximum number is 30,000.
      NOTE:
      • If the number of object types (such as tables and views) of the schema entered in Include is greater than the value of Load Limit, only the parent objects of the schema will be loaded. This indicates that child objects containing more than three parameters will not be loaded, such as columns, constraints, indexes, and functions.
      • Schema names provided in Include and Exclude are validated.
      • If you cannot access the schema specified in Include, an error message of the schema will be displayed during connection.
      • If you cannot access the schema specified in Exclude, the schema will not be loaded in Object Browser after the connection is created.

  6. Click OK.

    The status of the completed operation is displayed in the status bar.

    When Data Studio is connecting to the database, the connection status is displayed as follows:

    Once the connection is created, all schemas will be displayed in the Object Browser pane.

    NOTE:
    • Data Studio allows you to login even if the password has expired with a message informing that some operations may not work as expected. For details, see Password Expiry.
    • To cancel the connection, see Canceling the Connection.
    • PostgreSQL schema names are not displayed in the Object Browser pane.

Canceling the Connection

Perform the following steps to cancel the connection:

  1. Click Cancel.

    The Cancel Connection dialog box is displayed.

  2. Click Yes.

    A confirmation dialog box is displayed.

  3. Click OK.

Lazy Loading

The lazy loading feature allows objects to be loaded only when you need.

When you connect to a database only child objects of the schema saved under search_path will be loaded, as shown in the following figure.

Unloaded schemas are displayed as Schema name (...).

To load child objects, expand the schema. You will see that the objects under the schema are loading.

NOTE:

If you try to load an unloaded object while another object is being loaded, a pop-up message is displayed indicating that another object is being loaded. The next to the unloaded object will disappear, and will be displayed again when you refresh the object or database level to load the object.

Expand a schema to load and view the child objects. You can load child objects of only one schema at a time in Object Browser.

If you modify search_path after creating a connection, the modification will take effect only after the database is reconnected. The Auto Suggest feature is applicable to keywords, data types, schema names, table names, views, and table aliases of all schema objects that you have permissions for accessing.

A maximum of 50,000 objects will be loaded in the Object Browser pane within one minute.

The database connection timeout interval defaults to 3 minutes (180 seconds). If the connection fails within this interval, a timeout error is displayed.

You can set the loginTimeout value in the Data Studio.ini file located in the Data Studio\ directory.

NOTE:

When you log in to Data Studio, pg_catalog is loaded automatically.

We use cookies to improve our site and your experience. By continuing to browse our site you accept our cookie policy. Find out more

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback