You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hive.apache.org by indrani gorti <in...@gmail.com> on 2012/03/14 07:14:04 UTC

Hive

Hi
I understand that when we start the CLI we are in the default database.
This is rooted at

hive.warehouse.dir which is typically rooted at /user/hive/warehouse

we create a database in the default location is /user/hive/warehouse/
+ databasename +".db"
Cant we have two databases in the same location.  If I yes, how does
Hive differentiate between the databases and how is the appropriate
mapping done to tables.

Thanks in advance.

Indrani

Re: Hive

Posted by Edward Capriolo <ed...@gmail.com>.
That could happen (if hive lets you create a database with . in the
name, which I am not sure it does) but you should avoid that by
specifying the location of the database or table/database names that
do not collide. I so not see it as much of an issue. Write and enforce
a db/table naming policy and it will probably never happen.

Edward


On Wed, Mar 14, 2012 at 2:14 AM, indrani gorti <in...@gmail.com> wrote:
> Hi
> I understand that when we start the CLI we are in the default database.
> This is rooted at
>
> hive.warehouse.dir which is typically rooted at /user/hive/warehouse
>
> we create a database in the default location is /user/hive/warehouse/
> + databasename +".db"
> Cant we have two databases in the same location.  If I yes, how does
> Hive differentiate between the databases and how is the appropriate
> mapping done to tables.
>
> Thanks in advance.
>
> Indrani