Skip site navigation (1) Skip section navigation (2)

SVN Commit by dpage: r4215 - trunk/pgadmin3/xtra/pgagent

From: svn(at)pgadmin(dot)org
To: pgadmin-hackers(at)postgresql(dot)org
Subject: SVN Commit by dpage: r4215 - trunk/pgadmin3/xtra/pgagent
Date: 2005-05-19 09:42:43
Message-ID: 200505190942.j4J9ghoO011689@developer.pgadmin.org (view raw or flat)
Thread:
Lists: pgadmin-hackers
Author: dpage
Date: 2005-05-19 10:42:43 +0100 (Thu, 19 May 2005)
New Revision: 4215

Modified:
   trunk/pgadmin3/xtra/pgagent/job.cpp
   trunk/pgadmin3/xtra/pgagent/pgagent.sql
Log:
No need to dup the dbname and code from the step into the step log.

Modified: trunk/pgadmin3/xtra/pgagent/job.cpp
===================================================================
--- trunk/pgadmin3/xtra/pgagent/job.cpp	2005-05-19 09:27:24 UTC (rev 4214)
+++ trunk/pgadmin3/xtra/pgagent/job.cpp	2005-05-19 09:42:43 UTC (rev 4215)
@@ -89,8 +89,8 @@
 		{
 			jpsid=id->GetString("id");
 			DBresult *res=serviceConn->Execute(
-				"INSERT INTO pgagent.pga_jobsteplog(jslid, jsljlgid, jsldbname, jslcode) "
-				"SELECT " + jpsid + ", " + jobid + ", '" + steps->GetString("jstdbname") + "', jstcode "
+				"INSERT INTO pgagent.pga_jobsteplog(jslid, jsljlgid, jslstatus) "
+				"SELECT " + jpsid + ", " + jobid + ", 'r'"
 				"  FROM pgagent.pga_jobstep WHERE jstid=" + steps->GetString("jstid"));
 
 			if (res)

Modified: trunk/pgadmin3/xtra/pgagent/pgagent.sql
===================================================================
--- trunk/pgadmin3/xtra/pgagent/pgagent.sql	2005-05-19 09:27:24 UTC (rev 4214)
+++ trunk/pgadmin3/xtra/pgagent/pgagent.sql	2005-05-19 09:42:43 UTC (rev 4215)
@@ -114,21 +114,19 @@
 CREATE TABLE pgagent.pga_joblog (
 jlgid                serial               NOT NULL PRIMARY KEY,
 jlgjobid             int4                 NOT NULL REFERENCES pgagent.pga_job (jobid) ON DELETE CASCADE ON UPDATE RESTRICT,
-jlgstatus            char                 NOT NULL CHECK (jlgstatus IN ('r', 's', 'f', 'i', 'd')) DEFAULT 'r', -- running, success, failed, internal failure, died
+jlgstatus            char                 NOT NULL CHECK (jlgstatus IN ('r', 's', 'f', 'i')) DEFAULT 'r', -- running, success, failed, internal failure
 jlgstart             timestamptz          NOT NULL DEFAULT current_timestamp,
 jlgduration          interval             NULL
 ) WITHOUT OIDS;
 CREATE INDEX pga_joblog_jobid ON pgagent.pga_joblog(jlgjobid);
 COMMENT ON TABLE pgagent.pga_joblog IS 'Job run logs.';
-COMMENT ON COLUMN pgagent.pga_joblog.jlgstatus IS 'Status of job: r=running, s=successfully finished, f=failed';
+COMMENT ON COLUMN pgagent.pga_joblog.jlgstatus IS 'Status of job: r=running, s=successfully finished, f=failed, i=no steps to execute';
 
 
 
 CREATE TABLE pgagent.pga_jobsteplog (
 jslid                serial               NOT NULL PRIMARY KEY,
 jsljlgid             int4                 NOT NULL REFERENCES pgagent.pga_joblog (jlgid) ON DELETE CASCADE ON UPDATE RESTRICT,
-jsldbname            name                 NOT NULL,
-jslcode              text                 NOT NULL,
 jslstatus            char                 NOT NULL CHECK (jslstatus IN ('r', 's', 'i', 'f')) DEFAULT 'r', -- running, success, ignored, failed
 jslresult            int2                 NULL,
 jslstart             timestamptz          NOT NULL DEFAULT current_timestamp,


pgadmin-hackers by date

Next:From: svnDate: 2005-05-19 09:53:11
Subject: SVN Commit by dpage: r4216 - trunk/pgadmin3/xtra/pgagent
Previous:From: svnDate: 2005-05-19 09:27:24
Subject: SVN Commit by dpage: r4214 - trunk/pgadmin3/xtra/pgagent

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group