On Thu, Aug 14, 2008 at 20:27, Peter Eisentraut [EMAIL PROTECTED] wrote:
Am Thursday, 14. August 2008 schrieb Clemens Schwaighofer:
Why is Postgres not using the indexes in the 8.3 installation.
Might have something to do with the removal of some implicit casts. You
should show us your table definitions.
email table:
Table public.email
Column |Type |
Modifiers
+-+--
row_status | integer |
date_created | timestamp without time zone | default now()
date_updated | timestamp without time zone |
user_created | character varying(25) | default current_user()
user_updated | character varying(25) |
email_id | integer | not null default
nextval('email_email_id_seq'::regclass)
email_group_id | integer | not null
email | character varying |
status | smallint| default 0
custom_field_1 | character varying |
custom_field_2 | character varying |
custom_field_3 | character varying |
custom_field_4 | character varying |
custom_field_5 | character varying |
custom_field_6 | character varying |
custom_field_7 | character varying |
custom_field_8 | character varying |
custom_field_9 | character varying |
delete_mark| smallint|
checked_count | integer | default 0
error_count| integer | default 0
error_flag | smallint| default 0
key| character varying |
type | character varying |
Indexes:
email_pkey PRIMARY KEY, btree (email_id)
idx_email_email btree (email)
idx_email_email_group_id btree (email_group_id)
idx_email_status btree (status)
Foreign-key constraints:
email_email_group_id_fkey FOREIGN KEY (email_group_id) REFERENCES
email_group(email_group_id) MATCH FULL ON UPDATE CASCADE ON DELETE CASCADE
Triggers:
trg_email BEFORE INSERT OR UPDATE ON email FOR EACH ROW EXECUTE
PROCEDURE set_generic()
Inherits: generic
email_group table:
Table public.email_group
Column |Type
| Modifiers
+-+--
row_status | integer |
date_created | timestamp without time zone | default now()
date_updated | timestamp without time zone |
user_created | character varying(25) | default current_user()
user_updated | character varying(25) |
email_group_id | integer | not null default
nextval('email_group_email_group_id_seq'::regclass)
pre_email_group_id | integer |
edit_access_id | integer | not null
name | character varying | not null
group_type | smallint|
count | integer |
bad_count | integer |
hidden | smallint| default 0
Indexes:
email_group_pkey PRIMARY KEY, btree (email_group_id)
idx_email_group_edit_access_id btree (edit_access_id)
idx_email_group_pre_email_group_id btree (pre_email_group_id)
Foreign-key constraints:
email_group_edit_access_id_fkey FOREIGN KEY (edit_access_id)
REFERENCES edit_access(edit_access_id) MATCH FULL ON UPDATE CASCADE ON
DELETE RESTRICT
email_group_pre_email_group_id_fkey FOREIGN KEY (pre_email_group_id)
REFERENCES email_group(email_group_id) MATCH FULL ON UPDATE CASCADE ON
DELETE CASCADE
Triggers:
trg_email_group BEFORE INSERT OR UPDATE ON email_group FOR EACH ROW
EXECUTE PROCEDURE set_generic()
Inherits: generic
--
[ Clemens Schwaighofer -=:~ ]
[ IT Engineer/Manager ]
[ E-Graphics Communications, TEQUILA\ Japan IT Group ]
[ 6-17-2 Ginza Chuo-ku, Tokyo 104-8167, JAPAN ]
[ Tel: +81-(0)3-3545-7703 Fax: +81-(0)3-3545-7343 ]
[ http://www.tequila.jp ]
This e-mail is intended only for the named person or entity to which
it is addressed and contains valuable business information that is
privileged, confidential and/or otherwise protected from disclosure.
Dissemination, distribution or copying of this e-mail or the
information herein by anyone other than the intended recipient, or
an employee or agent responsible for delivering the message to the
intended recipient, is strictly prohibited. All contents are the
copyright property of TBWA Worldwide, its agencies or a client of
such agencies. If you are not the intended recipient, you are
nevertheless bound to respect the worldwide legal rights