dbTalk Databases Forums  

[BUGS] Why is the index not created in the tablespace delivered in

mailing.database.pgsql-bugs mailing.database.pgsql-bugs


Discuss [BUGS] Why is the index not created in the tablespace delivered in in the mailing.database.pgsql-bugs forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Michael Kleiser
 
Posts: n/a

Default [BUGS] Why is the index not created in the tablespace delivered in - 10-11-2004 , 11:18 AM






On PosgreSQl 8.0.0 beta 3 (on SuSE Linux 8.1) I tried this:

mkdir /opt/pgsql/data2
mkdir /opt/pgsql/data3
psql test1

test1=# CREATE TABLESPACE ts_test_1 OWNER testuser LOCATION '/opt/pgsql/data2';
CREATE TABLESPACE
test1=# CREATE TABLESPACE ts_test_2 OWNER testuser LOCATION '/opt/pgsql/data3';
CREATE TABLESPACE
test1=# \q

psql test1 testuser
test1=> create table foobar ( foo varchar(50) ) TABLESPACE ts_test_1;
CREATE TABLE
test1=> select * from pg_tables where tablespace='ts_test_1';
schemaname | tablename | tablespace | tableowner | hasindexes | hasrules | hastriggers
------------+-----------+------------+------------+------------+----------+-------------
public | foobar | ts_test_1 | testuser | f | f | f
(1 row)
test1=> create index ix_foobar on foobar(foo) TABLESPACE ts_test_2;
CREATE INDEX
test1=> select * from pg_indexes where tablename='foobar';
schemaname | tablename | tablespace | indexname | indexdef
------------+-----------+------------+-----------+-------------------------------------------------------------------------
public | foobar | ts_test_1 | ix_foobar | CREATE INDEX ix_foobar ON foobar USING btree (foo) TABLESPACE ts_test_2
(1 row)

Why is index "ix_foobar" in tablespace "ts_test_1" and not in tablespace "ts_test_2" ?
Is it a bug ?

regards
Michael Kleiser Web.de AG

---------------------------(end of broadcast)---------------------------
TIP 9: the planner will ignore your desire to choose an index scan if your
joining column's datatypes do not match

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.