Show
Ignore:
Timestamp:
05/29/07 15:52:59 (7 years ago)
Author:
robert
Message:

rename job_details to be consitent with the one true table name scheme

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/autonomous_logging_tool/autonomous_logging_tool.install.sql

    r3 r4  
    1616create index job_log_start_time_idx on alt.job_log(start_time); 
    1717 
    18 create table alt.job_details
     18create table alt.job_detail
    1919    job_id bigint not null references alt.job_log(job_id), 
    2020    step_id bigserial not null, 
     
    7676    v_step_id INTEGER; 
    7777BEGIN 
    78     SELECT nextval('alt.job_details_step_id_seq') INTO v_step_id; 
    79  
    80     INSERT INTO alt.job_details (job_id, step_id, action, start_time) 
     78    SELECT nextval('alt.job_detail_step_id_seq') INTO v_step_id; 
     79 
     80    INSERT INTO alt.job_detail (job_id, step_id, action, start_time) 
    8181    VALUES (p_job_id, v_step_id, p_action, current_timestamp); 
    8282 
     
    114114    v_numrows integer; 
    115115BEGIN 
    116     UPDATE alt.job_details SET  
     116    UPDATE alt.job_detail SET  
    117117        end_time = current_timestamp, 
    118118        elapsed_time = date_part('epoch',now() - start_time)::integer, 
  • trunk/autonomous_logging_tool/autonomous_logging_tool.test.sql

    r3 r4  
    33 
    44select add_step(1,'Step 1 For Job 1'); 
    5 select * from job_log join job_details using (job_id) order by job_id, step_id; 
     5select * from job_log join job_detail using (job_id) order by job_id, step_id; 
    66 
    77select upd_step(1,1,'OK','Update 1 For Step 1 For Job 1'); 
    8 select * from job_log join job_details using (job_id) order by job_id, step_id; 
     8select * from job_log join job_detail using (job_id) order by job_id, step_id; 
    99 
    1010select add_step(1,'Step 2 For Job 1'); 
    11 select * from job_log join job_details using (job_id) order by job_id, step_id; 
     11select * from job_log join job_detail using (job_id) order by job_id, step_id; 
    1212 
    1313select upd_step(1,2,'','Update 1 For Step 2 For Job 1'); 
    14 select * from job_log join job_details using (job_id) order by job_id, step_id; 
     14select * from job_log join job_detail using (job_id) order by job_id, step_id; 
    1515 
    1616select upd_step(1,2,'','Update 2 For Step 2 For Job 1'); 
    17 select * from job_log join job_details using (job_id) order by job_id, step_id; 
     17select * from job_log join job_detail using (job_id) order by job_id, step_id; 
    1818 
    1919select upd_step(1,2,'OK','Update 3 For Step 2 For Job 1'); 
    20 select * from job_log join job_details using (job_id) order by job_id, step_id; 
     20select * from job_log join job_detail using (job_id) order by job_id, step_id; 
    2121 
    2222select close_job(1); 
    23 select * from job_log join job_details using (job_id) order by job_id, step_id; 
     23select * from job_log join job_detail using (job_id) order by job_id, step_id; 
    2424 
    2525 
     
    2828 
    2929select add_step(2,'Step 1 For Job 2'); 
    30 select * from job_log join job_details using (job_id) order by job_id, step_id; 
     30select * from job_log join job_detail using (job_id) order by job_id, step_id; 
    3131 
    3232select upd_step(2,1,'OK','Update 1 For Step 1 For Job 2'); 
    33 select * from job_log join job_details using (job_id) order by job_id, step_id; 
     33select * from job_log join job_detail using (job_id) order by job_id, step_id; 
    3434 
    3535select fail_job(2); 
    36 select * from job_log join job_details using (job_id) order by job_id, step_id; 
     36select * from job_log join job_detail using (job_id) order by job_id, step_id;