Dbeaver установить драйвер oracle



How to install the database driver for Dbeaver without a network-Take installing the Oracle driver as an example

ready:

1. A computer that can connect to the network and has Dbeaver installed;
2. A U disk;
3. The target computer that cannot connect to the network.

Such asreferenceAs mentioned, it is recommended to set the download path of the driver to Alibaba Cloud. For the specific setting method, please refer to the article header display link.

Step 1: Open dbeaver on a computer with internet, and click Database>Driver Manager>Oracle>Edit in turn to enter the interface as shown in Figure 1:

Select any one in the green box No. 3, click Download/Update, hover the mouse over it after downloading, the corresponding local address will be displayed, and enter this address after downloading one by one. The author’s address is shown in Figure 2 below:

Step 2: Copy these files to a computer that cannot connect to the network via a USB flash drive, and select a folder address that you will not easily delete and store.

Step 3: Also click Database>Driver Manager>Oracle>Edit to enter the same interface. At this time, you need to delete all the drivers in the green box shown in Figure 1, and then click Add/Folder to add the drivers in Figure 2 one by one Just come in.

Источник

Connecting to Oracle Database using JDBC OCI driver

This article discusses how to establish connections to an Oracle database using JDBC OCI (Type II). Please take into consideration that the proposed way uses DBeaver’s Generic driver. It means that you cannot get Oracle-specific functionality this way.

Prerequisites

JDBC OCI connections require Oracle Instant Client on the local machine. Please pay attention to the Instant Client and the JDBC driver versions, as they must be identical. DBeaver uses the 12.2.0.1 version by default at the moment, so we recommend using the 12.2.0.1 version of the Instant Client.

Install the Instant Client into some folder. We will refer to this folder as ORA_HOME for the rest of the article. Append ORA_HOME to the PATH variable and restart DBeaver before proceeding.

Configuration

  1. Place your tnsnames.ora file into ORA_HOME/network/admin directory.
  2. In DBeaver, click Window -> Driver Manager -> New. This opens Create new driver dialog.
  3. In the Settings tab, add a Driver name of your liking. Set Class Name to ‘oracle.jdbc.OracleDriver’. Set URL Template to ‘jdbc:oracle:oci:@tnsAlias’, where ‘tnsAlias’ is an alias from your tnsnames.ora file. Make sure that the Driver Type is set to Generic.
  4. In the Libraries tab, you need to add Maven artifacts. To do that, click Add Artifact. Paste the following XML into the text field:

NB: Replace the versions of the artifacts if you use a different version of the Instant Client.

  1. In the Driver properties tab, make right-click -> Add new property.
  2. Set the property name to ‘protocol’ (without quotes). Set the Value to ‘oci’ (without quotes).
  3. Close the Driver manager.
  4. Create a new connection using your newly configured driver.

Источник

Oracle

General User Guide

  • Installation
  • Application Window Overview
  • Views
    • Database Navigator
      • Filter Database Objects
      • Configure Filters
      • Simple and Advanced View
    • Projects View
    • Project Explorer
    • Query Manager
    • Background Tasks
  • Database Object Editor
    • Properties Editor
  • Data Editor
    • Navigation
    • Data View and Format
    • Data Filters
    • Data Refresh
    • Data Viewing and Editing
    • Panels
    • Managing Charts
    • Data Search
    • SQL Generation
    • Working with spatial/GIS data
    • Working with XML and JSON
    • Managing Data Formats
    • Virtual column expressions
  • SQL Editor
    • SQL Templates
    • SQL Assist and Auto-Complete
    • SQL Formatting
    • SQL Execution
    • SQL Terminal
    • Variables panel
    • Query Execution Plan
    • Visual Query Builder
    • Script Management
    • Client Side Commands
      • Export Command
    • Debug
      • PostgreSQL Debugger
  • ER Diagrams
    • Database Structure Diagrams
    • Custom Diagrams
    • Edit mode
  • Search
    • File Search
    • DB Full-Text Search
    • DB Metadata Search
  • Schema compare
  • Data compare
  • MockData generation
  • Dashboards, DB monitoring
  • Projects
    • Project security
    • Team work (Git)
  • Bookmarks
  • Shortcuts
  • Sample Database
  • Database Connections
    • Create Connection
    • Edit Connection
    • Connect to Database
    • Invalidate/Reconnect to Database
    • Disconnect from Database
    • Change current user password
    • Advanced settings
      • SSH Configuration
      • Proxy configuration
      • SSL configuration
      • Kerberos authentication
      • Network Profiles
  • Connection Types
  • Transactions
    • Auto and Manual Commit Modes
    • Transaction Log
    • Pending transactions
  • Database drivers
  • Tasks
    • Data export/import
    • Data migration
    • Data Import and Replace
    • Database backup/restore
    • Database maintenance tools
    • Task management
    • Task scheduler
    • Composite tasks
    • Sending results by e-mail
  • Cloud Explorer
    • AWS
    • AWS Credentials
    • AWS SSO
    • GCP Credentials
    • GCP SSO

Enterprise Databases support

  • MongoDB
  • Cassandra
  • InfluxDB
  • Redis
  • AWS (Amazon Web Services)
    • DynamoDB
    • DocumentDB
    • Athena
    • Keyspaces
  • GCP (Google Cloud Platform)
    • Bigtable
  • Couchbase
  • CouchDB
  • Apache Hive/Spark/Impala
  • Netezza
  • Oracle
  • SQLite Crypt
  • Informix

License management

  • License Administration
  • How to Import License
  • How to Reassign License
Clone this wiki locally

Connecting to Oracle databases

There are several ways to configure a database connection and several ways to perform an authentication.

Host/port based configuration

Parameter Description Example
Host Server host name 192.168.1.25
Post number Server listener port 1521 (default)
Database Service or SID name ORCL
Service/SID It depends on the server configuration.
SID must be selected for some servers and the Service Name for others
SID

TNS configuration is the simplest but it requires you to have the tnsnames.ora file somewhere on your disk. tnsnames.ora contains information about all accessible Oracle server connections. DBeaver can determine the default location of this file but sometimes you will need to manually specify it.

Parameter Description Example
Network Alias Name of configuration from tnsnames.ora ORCL1
TNS names path Path to tnsnames.ora file.
By default, it is got from the TNS_ADMIN environment variable or from Windows’ registry
c:\oracle\network\admin

For more a sophisticated configuration, you can specify the full JDBC URL manually (see Data Sources and URLs).

Sample URL (Oracle Cloud):
jdbc:oracle:thin:@(description= (retry_count=20)(retry_delay=3)(address=(protocol=tcps)(port=1522)(host=adb.us-ashburn-1.oraclecloud.com))(connect_data=(service_name=xxxxxxxxxxxxxxxxx_high.adb.oraclecloud.com))(security=(ssl_server_cert_dn=»CN=adwc.uscom-east-1.oraclecloud.com, OU=Oracle BMCS US, O=Oracle Corporation, L=Redwood City, ST=California, C=US»)))

Parameter Description Example
User name Database user name SYS
Password Database user password
Role Role for connection.
Roles SYSDBA and SYSOPER are needed for some administrative operations
Normal
Save password Saves the user/password information in the local DBeaver configuration SID

The Oracle driver gets user information from the current OS user.
You do not need to explicitly specify any credentials.

A more secure way to connect is to use the Oracle Wallet. Wallet is a directory with security keys and some other optional connection information. Wallets are usually distributed as ZIP archives. You need to extract the ZIP archive to a folder on a disk and specify this folder in the Wallet location field.

Wallet may contain information about a database user. This, however, is optional. You will sometimes need to specify the user too.

Wallet may also contain a TNS configuration. If it does, you can use the TNS connection configuration easily by setting the TNS path to the same value as the Wallet location .

Parameter Description Example
User name, Password, Role See Database authentication
Wallet location Oracle wallet directory C:\oracle\network\wallet\example
Wallet password Optional. Some wallets are password-protected

Kerberos is the most complicated authentication in Oracle.

Parameter Description Example
Username Database user name c##testuser
Kerberos user Kerberos / Active directory user name testuser@THE-REALM
Realm Kerberos realm THE-REALM
KDC server KDC server address krb5.your-domain.com
Password Kerberos user password

Oracle Cloud connections

DBeaver supports Oracle Cloud Autonomous databases connectivity.
There are two ways to authenticate:

Plain URL connection

  • To use a plain URL connection you must enable the Access control list for the Oracle autonomous database.
  • Then add your IP address to the IP list.
  • Use the Custom connection configuration (URL). You can copy the URL from the Oracle Cloud database page (link «DB Connection»).

Oracle Wallet connection

It is the default authentication type for the Oracle Cloud.
.

  • Download Wallet from the Oracle Cloud website
  • Expand the wallet archive to a folder
  • Set TNS configuration type
  • Set the TNS path to the wallet location directory
  • Choose the proper Network Alias from the drop-down menu
  • Set Authentication to the Oracle Wallet
  • Set the database user name and password (you can get them from the Oracle Cloud database information page)
  • Set the Wallet location to the wallet location directory

Источник

Database drivers

General User Guide

  • Installation
  • Application Window Overview
  • Views
    • Database Navigator
      • Filter Database Objects
      • Configure Filters
      • Simple and Advanced View
    • Projects View
    • Project Explorer
    • Query Manager
    • Background Tasks
  • Database Object Editor
    • Properties Editor
  • Data Editor
    • Navigation
    • Data View and Format
    • Data Filters
    • Data Refresh
    • Data Viewing and Editing
    • Panels
    • Managing Charts
    • Data Search
    • SQL Generation
    • Working with spatial/GIS data
    • Working with XML and JSON
    • Managing Data Formats
    • Virtual column expressions
  • SQL Editor
    • SQL Templates
    • SQL Assist and Auto-Complete
    • SQL Formatting
    • SQL Execution
    • SQL Terminal
    • Variables panel
    • Query Execution Plan
    • Visual Query Builder
    • Script Management
    • Client Side Commands
      • Export Command
    • Debug
      • PostgreSQL Debugger
  • ER Diagrams
    • Database Structure Diagrams
    • Custom Diagrams
    • Edit mode
  • Search
    • File Search
    • DB Full-Text Search
    • DB Metadata Search
  • Schema compare
  • Data compare
  • MockData generation
  • Dashboards, DB monitoring
  • Projects
    • Project security
    • Team work (Git)
  • Bookmarks
  • Shortcuts
  • Sample Database
  • Database Connections
    • Create Connection
    • Edit Connection
    • Connect to Database
    • Invalidate/Reconnect to Database
    • Disconnect from Database
    • Change current user password
    • Advanced settings
      • SSH Configuration
      • Proxy configuration
      • SSL configuration
      • Kerberos authentication
      • Network Profiles
  • Connection Types
  • Transactions
    • Auto and Manual Commit Modes
    • Transaction Log
    • Pending transactions
  • Database drivers
  • Tasks
    • Data export/import
    • Data migration
    • Data Import and Replace
    • Database backup/restore
    • Database maintenance tools
    • Task management
    • Task scheduler
    • Composite tasks
    • Sending results by e-mail
  • Cloud Explorer
    • AWS
    • AWS Credentials
    • AWS SSO
    • GCP Credentials
    • GCP SSO

Enterprise Databases support

  • MongoDB
  • Cassandra
  • InfluxDB
  • Redis
  • AWS (Amazon Web Services)
    • DynamoDB
    • DocumentDB
    • Athena
    • Keyspaces
  • GCP (Google Cloud Platform)
    • Bigtable
  • Couchbase
  • CouchDB
  • Apache Hive/Spark/Impala
  • Netezza
  • Oracle
  • SQLite Crypt
  • Informix

License management

  • License Administration
  • How to Import License
  • How to Reassign License
Clone this wiki locally

You can use a pre-configured database driver or create a new driver.

DBeaver has a lot of pre-configured drivers including SQL, NoSQL, key-value databases, graph databases, search engines, etc. But sometimes you need to connect to a database which was not configured in DBeaver yet.

All you need is a JDBC driver of your database. The rest is easy.

Obtaining JDBC driver

JDBC driver is a program (in Java) which can connect and operate with some local or remote database server. It usually provides all needed functionality to cover 100% of database functionality. The JDBC driver is usually provided by database vendors to allow customers to work with their databases.

The JDBC driver consists of one or multiple jar files. The Jar file is a library which contains program code and some other files. You need to download the driver’s jar files before adding them to DBeaver. Sometimes the jar files are included in the database server distribution — in that case you need to refer to your database documentation or ask your DBA.

Adding driver configuration in DBeaver

Open driver manager dialog

You can open the driver manager from the main menu:

or from Database Navigator drop-down menu.

Add a new driver

Just click the button New and create a new driver. On the driver edit dialog you need to enter all required information:

Parameter Description
Driver Name Name of your driver. It can be any name you like
Driver Type Driver provider. In 99% cases you will need a generic driver (JDBC provider)
Class Name JDBC driver class name. You can get it from the documentation or find it in the jar files (see «Find Class» button description)
URL Template Template of driver URL. You can leave it empty. But in this case you will be ready to set JDBC URL for each your connection. It is better to define a valid template, which will greatly simplify the connections creation. See «URL Templates» for a detailed description
Default Port Default database port. You can get it from the documentation or leave it empty
Embedded Enable it for server-less databases. This flag affects a few config options related to the network/connections management
No Authentication This means that driver does not require authentication (no user/password fields will be shown)
Category Driver category, deprecated
ID Driver unique ID, ignore it
Description Driver description, it is shown in some dialogs/wizards as a hint

This is the list of jar files, binary libraries (dll or so) and any other files required by the driver. In most cases you only need the jar files.
Click «Add File» to add a single jar file, «Add Folder» to add to the folder with Java classes/resources and «Add Artifact» to add the Maven artifact (see below).

After you add the jar files you will be able to find all JDBC driver classes which are found in these jars. Just click on the «Find Class» button and DBeaver will show all of them. In most cases there is just one driver class in the driver. If there are many of them, you need to refer to the driver’s documentation.

DBeaver can download driver jars directly from the Maven repository (it is a global public repository of Java libraries, usually an open-source). If your database driver is published on some public repository you can use this feature. Maven artifacts are better than plain jar files because you can see all existing driver versions and can change the driver version in runtime without any driver properties reconfiguration.

Saving driver, adding connection

After you have finished configuring your driver, just press the Ok button.
Now you can create connection.

If you need to change some driver properties later you can access them directly from connection properties dialog:

JDBC drivers use URLs to identify remote servers — strings similar to classic web URLs. Usually, URL has form jdbc:vendor:host:port/database , for example `jdbc:postgresql:localhost:5432/postgres’. It is not very convenient to edit such a long and an unobvious string. DBeaver can construct this URL from connection parameters (like host, port, etc).

For example above the URL template is: jdbc:postgresql://:/
Host, port and database are parameters which you will need to enter on the connection configuration page.

Supported URL variables:

Parameter Description
Database server host name
Database server port number
Target database name
Target server name (rarely used)
Folder path (on the local file system). Used for embedded drivers
File path (on the local file system). Used for embedded drivers

For most drivers you do not need to change any advanced properties. But in some cases you can use this as driver tuning, e.g. for better performance or for structure fixing.

Parameter Description
Driver supports indexes Driver supports table indexes
Driver supports stored code Whether this driver supports stored code (procedures, functions, packages, etc)
Driver supports references Driver supports table references (foreign keys)
Driver supports SELECT count(*) clause Driver supports SELECT count(*) clause
Driver supports views Driver supports table views
Split procedures and functions Show procedures and functions in different folders
Script delimiter Literal for SQL queries separation in scripts
Script delimiter redefiner SQL clause which redefines script delimiter value
Use script delimiter after query Keep SQL script delimiter after each SQL query
Use script delimiter after SQL block Keep SQL script delimiter after SQL script blocks (BEGIN/END)
String escape character Character used to escape special symbols in strings
Meta model type Type of metadata reading model — standard or indexed
All Objects Pattern SQL pattern for all metadata objects
Omit catalog(s) Do not read and use catalog (aka database) information
Omit single catalog Hide catalog (database) if there is only one catalog on server
Omit schema(s) Do not read and use schemas information
Omit single schema Hide schema if there is only one schema on the server
Use schema filters Use JDBC schema filters when the database does not support catalogs. Otherwise just read all database schemas and filter on client-side
Omit type cache Do not use data types provided by driver
Shutdown parameter Database shutdown URL parameter
Create database parameter Database create URL parameter
Driver supports multiple results Driver supports multiple results for a single query
Driver supports result set limit Driver supports multiple result set limit (max rows)
Driver supports structure cache Driver supports structure cache reading. Enables schema columns, keys, etc
Driver supports TRUNCATE operation Driver supports TRUNCATE command. It is much faster than DELETE without criteria

Queries (Custom driver queries)

Parameter Description
Get active database Query to obtain active database name
Set active database Query to change active database
Shutdown database Query to shutdown active database connection. Used for some embedded databases
PING query Query to check connection state
Dual table name Name of dummy ‘DUAL’ table which is used for expressions evaluation
Active object type Type of selectable object (schema, catalog)
Driver supports results scrolling Driver supports resultset scrolling
Quote reserved words Quote columns/table names if they conflicts with reserved SQL keywords
Escape LIKE masks in search queries Use to access JDBC metadata API. Enabled by default but should be disabled for some (broken) drivers

DDL (DDL generation options)

Parameter Description
Drop column short syntax Use ‘ALTER TABLE DROP column-name’ instead of standard syntax
Drop column — use brackets Use ‘ALTER TABLE DROP (column-name)’ instead of standard syntax
Use legacy SQL dialect for DDL Use legacy SQL dialect for DDL
Add COLUMN keyword in alter table query Add COLUMN keyword after keyword ADD and before column name in alter table query

Formatting (SQL values formats)

Parameter Description
Timestamp format Format pattern for timestamp columns
Date format Format pattern for date columns
Time format Format pattern for time columns

If you have configured some driver, it works well and you think that it makes sense to have this driver configuration in standard DBeaver, please send your configuration to us. Just create a feature request issue on GitHub and copy/paste driver description to the ticket (in any suitable form).

Источник

You may also like...

Adblock
detector