Show
Ignore:
Timestamp:
01/23/05 11:58:22 (19 years ago)
Author:
jalet
Message:

Added a few indexes for the database

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • pykota/trunk/initscripts/postgresql/pykota-postgresql.sql

    r2028 r2037  
    2020-- 
    2121-- $Log$ 
     22-- Revision 1.15  2005/01/23 10:58:22  jalet 
     23-- Added a few indexes for the database 
     24-- 
    2225-- Revision 1.14  2005/01/17 08:44:24  jalet 
    2326-- Modified copyright years 
     
    133136                        datelimit TIMESTAMP, 
    134137                        warned INT4 DEFAULT 0); -- not a boolean, will help stats 
     138CREATE INDEX userpquota_u_id_ix ON userpquota (userid); 
     139CREATE INDEX userpquota_p_id_ix ON userpquota (printerid); 
    135140CREATE UNIQUE INDEX userpquota_up_id_ix ON userpquota (userid, printerid); 
    136141                         
     
    157162                        jobdate TIMESTAMP DEFAULT now(), 
    158163                        CONSTRAINT checkUserPQuota FOREIGN KEY (userid, printerid) REFERENCES userpquota(userid, printerid)); 
     164CREATE INDEX jobhistory_u_id_ix ON jobhistory (userid); 
    159165CREATE INDEX jobhistory_p_id_ix ON jobhistory (printerid); 
    160166CREATE INDEX jobhistory_pd_id_ix ON jobhistory (printerid, jobdate);