Import data from a database into Insight.

次のようなユース ケースがあり得ます。


Import Type Fields

These are the module type specific fields that need to be configured for this import type. All of these fields are mandatory.

設定

説明

URL

The database connection URL

ドライバー

データベースへの接続に使用するドライバー クラス。

JDBC ドライバー (*.jar) を <Jira_INSTALL>/lib フォルダーに配置します。

lib フォルダーにドライバーを追加後、Jira を必ず再起動してください。

ユーザ名

The username used to authenticate

パスワード

The password used to authenticate

データベースのパスワードを入力します。

If you then come to edit your database import later, the password field will be disabled. If you want to edit the password, you have to check the Change value checkbox provided adjacent to the Password field as shown in the screenshot below.

To save your edited password, make sure you keep the Change value checkbox checked until you click on the Next button. If you uncheck it accidentally, the password field is disabled again with its original value retained and the newly entered password will not be saved.

If you want to query the Jira database, you can look into the dbconfig.xml found in Jira_HOME directory, to find out the correct configuration.

Object Type Mapping configuration

名前説明
セレクター

データベース インポートのセレクターは SQL クエリです。SQL クエリの構築方法は、データベース タイプによって異なります。

セレクター (SQL 文) の構築方法は、データベース接続の設定方法によって異なります。次に、セットアップ時にこれを正しく設定するガイドとなる例をいくつか示します。

データベースタイプ
Microsoft SQL Server

select * from <database.name>.<schema-name>.Application

<schema-name> は既定で「dbo」のため、例は次のようになります。

select * from dbname.dbo.Application
Oracle

select * from <schema-name>.Application

<schema-name> が "Jiraschema" の場合、クエリは次のようになります。

select * from Jiraschema.Application
PostgreSQL
select * from "Application"
MySQL
select * from Application

If you want to query the Jira database, you can look into the dbconfig.xml found in Jira_HOME directory, to find out the correct configuration, such as schema name etc.

Predefined Structure & Configuration

There are no predefined structure and configuration implemented for the Database type

Supported database types

We are using a common framework (jdbc) to connect to the database so we support many database types such as:

データベースタイプドライバー

Microsoft SQL Server

before Jira 7.5 net.sourceforge.jtds.jdbc.Driver

after Jira 7.5 com.microsoft.sqlserver.jdbc.SQLServerDriver

Oracle

oracle.jdbc.OracleDriver

PostgreSQL

org.postgresql.Driver

MySQL

com.mysql.jdbc.Driver


URL Examples

If you want to connect to the Jira database, you can look into the dbconfig.xml in Jira_HOME to find the correct configuration and URL

Here are some examples of URL configurations for different database types:

データベースタイプURL

Microsoft SQL Server

before Jira 7.5 jdbc:jtds:sqlserver://localhost:41972/Jiradb

after Jira 7.5 jdbc:sqlserver://localhost:1433;databaseName=Jiradb

Oracle

jdbc:oracle:thin:@//localhost:1521/ORCL

PostgreSQL

jdbc:postgresql://localhost:5433/Jiradb

MySQL

jdbc:mysql://localhost:3306/Jiradb?useUnicode=true&amp;characterEncoding=UTF8&amp;sessionVariables=storage_engine=InnoDB


Another connection example:

Connection URL with domain for AD authentication:
URL: jdbc:jtds:sqlserver://10.10.1.1:1433/DB;domain=example.com
Driver: net.sourceforge.jtds.jdbc.Driver