On Fri, 2003-12-05 at 13:04, Zabach, Elke wrote:
> Thomas Cataldo wrote:
> > 
> > UPDATE toc_tree 
> > SET 
> > lft = (CASE WHEN lft > 2   THEN lft + 2  ELSE lft END),  
> > rgt = (CASE WHEN rgt >= 2  THEN rgt + 2  ELSE rgt END)  
> > WHERE rgt >= 2
> >
> BTW: why do you have thise case/decode/subquery for RGT
> if only values which will be increased by 2 are qualified? Why not just do
> RGT = RGT+2?
> Is this a problem of simplifying an existing update for sending it to the list?

The '2' in the boolean expressions are parameters. And you're right, I
do not need the second 'case when'

Thanks you for you fast answer and very usefull hints.



-- 
MaxDB Discussion Mailing List
For list archives: http://lists.mysql.com/maxdb
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to