pg.ddx.io pgsql-sql@postgresql.org mailing list archive
help / color / mirror / Atom feedpartial index on non default tablespace syntax
4+ messages / 3 participants
[nested] [flat]
* partial index on non default tablespace syntax
@ 2005-06-18 16:54 Rajesh Kumar Mallah <mallah.rajesh@gmail.com>
0 siblings, 2 replies; 4+ messages in thread
From: Rajesh Kumar Mallah @ 2005-06-18 16:54 UTC (permalink / raw)
To: pgsql-sql
Hi,
Looks like its not possible to specify tablespace of an index with a
where clause,
we require to create the index, and then use ALTER INDEX for setting
the tablespace. Is it something that is already known or its itentional so as
to keep the command unambigious. i also could not find it in the TODO
Regds
Rajesh Kumar Mallah.
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: partial index on non default tablespace syntax
@ 2005-06-18 17:27 Michael Fuhr <mike@fuhr.org>
parent: Rajesh Kumar Mallah <mallah.rajesh@gmail.com>
1 sibling, 1 reply; 4+ messages in thread
From: Michael Fuhr @ 2005-06-18 17:27 UTC (permalink / raw)
To: Rajesh Kumar Mallah <mallah.rajesh@gmail.com>; +Cc: pgsql-sql
On Sat, Jun 18, 2005 at 10:24:06PM +0530, Rajesh Kumar Mallah wrote:
>
> Looks like its not possible to specify tablespace of an index with a
> where clause,
Could you show the command you're running and the error you get,
or otherwise explain what problem you're seeing? Is the following
not what you're looking for?
CREATE INDEX foo_name_idx ON foo (name)
TABLESPACE testspace
WHERE name IS NOT NULL;
http://www.postgresql.org/docs/8.0/static/sql-createindex.html
--
Michael Fuhr
http://www.fuhr.org/~mfuhr/
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: partial index on non default tablespace syntax
@ 2005-06-18 17:40 Tom Lane <tgl@sss.pgh.pa.us>
parent: Rajesh Kumar Mallah <mallah.rajesh@gmail.com>
1 sibling, 0 replies; 4+ messages in thread
From: Tom Lane @ 2005-06-18 17:40 UTC (permalink / raw)
To: Rajesh Kumar Mallah <mallah.rajesh@gmail.com>; +Cc: pgsql-sql
Rajesh Kumar Mallah <mallah.rajesh@gmail.com> writes:
> Looks like its not possible to specify tablespace of an index with a
> where clause,
Hm?
regression=# create table foo(f1 int, f2 int);
CREATE TABLE
regression=# create index fooi on foo (f1) tablespace pg_default where f2 < 0;
CREATE INDEX
(I hadn't bothered to make a tablespace to test with, but the point
is the syntax is fine.)
regards, tom lane
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: partial index on non default tablespace syntax
@ 2005-06-19 06:21 Rajesh Kumar Mallah <mallah.rajesh@gmail.com>
parent: Michael Fuhr <mike@fuhr.org>
0 siblings, 0 replies; 4+ messages in thread
From: Rajesh Kumar Mallah @ 2005-06-19 06:21 UTC (permalink / raw)
To: Michael Fuhr <mike@fuhr.org>; +Cc: pgsql-sql
Fuhr,Tom and Everyone
Extremely sorry for not consulting the docs.
I was doing this:
CREATE INDEX foo_name_idx ON foo (name)
WHERE name IS NOT NULL TABLESPACE testspace ;
Regds
Rajesh Kumar Mallah.
On 6/18/05, Michael Fuhr <mike@fuhr.org> wrote:
> On Sat, Jun 18, 2005 at 10:24:06PM +0530, Rajesh Kumar Mallah wrote:
> >
> > Looks like its not possible to specify tablespace of an index with a
> > where clause,
>
> Could you show the command you're running and the error you get,
> or otherwise explain what problem you're seeing? Is the following
> not what you're looking for?
>
> CREATE INDEX foo_name_idx ON foo (name)
> TABLESPACE testspace
> WHERE name IS NOT NULL;
>
> http://www.postgresql.org/docs/8.0/static/sql-createindex.html
>
> --
> Michael Fuhr
> http://www.fuhr.org/~mfuhr/
>
^ permalink raw reply [nested|flat] 4+ messages in thread
end of thread, other threads:[~2005-06-19 06:21 UTC | newest]
Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2005-06-18 16:54 partial index on non default tablespace syntax Rajesh Kumar Mallah <mallah.rajesh@gmail.com>
2005-06-18 17:27 ` Michael Fuhr <mike@fuhr.org>
2005-06-19 06:21 ` Rajesh Kumar Mallah <mallah.rajesh@gmail.com>
2005-06-18 17:40 ` Tom Lane <tgl@sss.pgh.pa.us>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox