You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@tajo.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2016/03/30 08:20:25 UTC
[jira] [Commented] (TAJO-2103) JdbcMetadataProviderBase need to
differentiate between database name in DBMS and database name in Tajo.
[ https://issues.apache.org/jira/browse/TAJO-2103?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15217479#comment-15217479 ]
ASF GitHub Bot commented on TAJO-2103:
--------------------------------------
GitHub user blrunner opened a pull request:
https://github.com/apache/tajo/pull/990
TAJO-2103: JdbcMetadataProviderBase need to differentiate between database name in DBMS and database name in Tajo.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/blrunner/tajo jdbc-mapped-database
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/tajo/pull/990.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #990
----
commit 5d8bfcc1bedc0de0dff82aa22784ca5286cb4662
Author: JaeHwa Jung <bl...@apache.org>
Date: 2016-03-28T04:31:41Z
Add mappedDatabaseName to JdbcMetadataProviderBase
commit 81f6e6ff53dd498a36e76c25285e28c6ce662e1f
Author: JaeHwa Jung <bl...@apache.org>
Date: 2016-03-28T05:05:03Z
Merge branch 'master' of https://git-wip-us.apache.org/repos/asf/tajo into jdbc-mapped-database
commit 809fb3de39d7ec9ef253df015bae9fbe60412414
Author: JaeHwa Jung <bl...@apache.org>
Date: 2016-03-30T01:20:28Z
Merge branch 'master' of https://git-wip-us.apache.org/repos/asf/tajo into jdbc-mapped-database
----
> JdbcMetadataProviderBase need to differentiate between database name in DBMS and database name in Tajo.
> -------------------------------------------------------------------------------------------------------
>
> Key: TAJO-2103
> URL: https://issues.apache.org/jira/browse/TAJO-2103
> Project: Tajo
> Issue Type: Bug
> Components: JDBC Storage
> Reporter: Jaehwa Jung
> Assignee: Jaehwa Jung
>
> When using {{mapped_database}} configuration in JDBCTablespace, users can map actual database name in RDBMS to virtual database name in Tajo. If users set tajo-storage.json as follow:
> {code:xml}
> {
> "spaces": {
> "pgsql_db1": {
> "uri": "jdbc:postgresql://hostname:port/db1",
> "configs": {
> "mapped_database": "tajo_db1",
> "connection_properties": {
> "user": "tajo",
> "password": "xxxx"
> }
> }
> }
> }
> }
> {code}
> In above example, the database db1 in PostgreSQL will be mapped the database tajo_db1 in Tajo. And users can write select statement, for example, "SELECT * from tajo_db1.Xyz".
> But actually, if mapped database name is not equals to actual database name, users won't be able to get table in Tajo because {{JdbcMetadataProviderBase}} always get table with mapped database name. The provider need to differentiate between database name in DBMS and database name in Tajo.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)