mos wrote:
I'm using MySQL 5.1.30 (WinXP) and user defined variables don't seem to
be working properly if the Select statement is sorted.
Here is a simple example:
CREATE TABLE `tmp` (
`Purch_Date` date DEFAULT NULL,
`Product` char(10) DEFAULT NULL
) ENGINE=MyISAM
On Mon, Jan 19, 2009 at 4:14 AM, b my...@logi.ca wrote:
mos wrote:
I'm using MySQL 5.1.30 (WinXP) and user defined variables don't seem to be
working properly if the Select statement is sorted.
Here is a simple example:
CREATE TABLE `tmp` (
`Purch_Date` date DEFAULT NULL,
At 03:14 AM 1/19/2009, b wrote:
mos wrote:
I'm using MySQL 5.1.30 (WinXP) and user defined variables don't seem to
be working properly if the Select statement is sorted.
Here is a simple example:
CREATE TABLE `tmp` (
`Purch_Date` date DEFAULT NULL,
`Product` char(10)
mos wrote:
At 03:14 AM 1/19/2009, b wrote:
mos wrote:
I'm using MySQL 5.1.30 (WinXP) and user defined variables don't seem
to be working properly if the Select statement is sorted.
Here is a simple example:
CREATE TABLE `tmp` (
`Purch_Date` date DEFAULT NULL,
`Product`
This means anytime a user defined variable like @num := @num + 1 and is
used in a query that is sorted, it is going to have to be changed to a
subquery. For example, if someone was using it to display detail line item
numbers on an invoice, it now has to be turned into a subselect. This breaks
I'm using MySQL 5.1.30 (WinXP) and user defined variables don't seem to be
working properly if the Select statement is sorted.
Here is a simple example:
CREATE TABLE `tmp` (
`Purch_Date` date DEFAULT NULL,
`Product` char(10) DEFAULT NULL
) ENGINE=MyISAM DEFAULT