Re: [GENERAL] Auto Ordering

1999-11-01 Thread amy cheng
then, why use int, isn't char better? (almost no need for batch). >From: Herouth Maoz <[EMAIL PROTECTED]> >To: "Shawn T. Walker" <[EMAIL PROTECTED]> >CC: [EMAIL PROTECTED] >Subject: Re: [GENERAL] Auto Ordering >Date: Mon, 1 Nov 1999 17:57:13 +0200 >

Re: [GENERAL] Auto Ordering

1999-11-01 Thread Herouth Maoz
At 20:41 +0200 on 27/10/1999, Stuart Rison wrote: > In the example you give, you could do the changes with two UPDATE > commands: > > 1) UPDATE questions SET order=0 WHERE order=5; > 2) UPDATE questions SET order=order+1 WHERE order<5; > > It becomes more tricky when you try and move a question

[GENERAL] Auto Ordering

1999-10-27 Thread Shawn T. Walker
Hi All, I have a table of questions to be displayed to the user. Table: questions question_id SERIAL page int order int question varchar(100) answers text The field order is how the questions are sorted. How can I change change question 5 to be number one and have all the other questions re