Re: CVS ltp/admin/supporter

From: Martin Schulze (joey@infodrom.org)
Date: Sat May 11 2002 - 15:55:27 CEST


Erik Tews wrote:
> On Sat, May 11, 2002 at 09:27:17AM +0200, CVS User joey wrote:
> > Update of /var/cvs/ltev/ltp/admin/supporter
> > In directory luonnotar:/tmp/cvs-serv9100
> >
> > Modified Files:
> > update.wml
> > Log Message:
> > Even though this looks like a large change, it's a very small change
> > but with large impact. It only adds support for deleting a job with
> > all fragments in place (first 6 lines). The remaining patch is only
> > indention due to if () {} else {...}
> >
> > --- /var/cvs/ltev/ltp/admin/supporter/update.wml 2002/05/10 19:15:46 1.19
> > +++ /var/cvs/ltev/ltp/admin/supporter/update.wml 2002/05/11 07:27:17 1.20
> > @@ -177,68 +177,46 @@
> > # Begin transaction
> > pg_exec($dbh, "BEGIN TRANSACTION") or die ("Could not start transaction.");
> >
> > - if (!strlen ($section))
> > - {
> > + if ($id > 0 && $delete == 1) {
> > + $query = sprintf ("DELETE FROM job WHERE id = %d", $id);
> > + pg_exec($dbh, $query) or die ("Can't delete job.");
> > + $query = sprintf ("DELETE FROM jobfragment WHERE jobid = %d", $id);
> > + pg_exec($dbh, $query) or die ("Can't delete job fragments.");
> > + } else {
>
> Ich glaube die 2. Query kannst du weglassen, das sollte kaskadieren:

Nur bei einem neuren Postgresql... ich teste mit einem potato-System... *floet*

Gruesse,

        Joey

-- 
It's time to close the windows.



This archive was generated by hypermail 2.1.3 : Sat May 11 2002 - 15:57:13 CEST