[Wifidog] More MySQL Problems (With Patch) in WifiDog-Auth SQLcode,

Rikhardur.EGILSSON at oecd.org Rikhardur.EGILSSON at oecd.org
Fri Oct 1 03:53:47 EDT 2004

-----Original Message-----
From: Wifidog-bounces at isf.waglo.com [mailto:Wifidog-bounces at isf.waglo.com] On
Behalf Of Alexandre Carmel-Veilleux
Sent: 30 September, 2004 11:51 PM
To: The WiFi Guard Dog project
Subject: Re: [Wifidog] More MySQL Problems (With Patch) in WifiDog-Auth

>> Let me try to understand:
>> [...]
>> 	WHERE (user_id = '$user' OR email = '$user')
>> [...]
>> Would be replaced by:
>> [...]
>> 	WHERE (users.user_id = '$user' OR email = '$user')
>> [...]
>	To me, this seems like a bug. It should either work in both or fail
in both.

I agree, the full MySQL error is 
"ERROR 1052 (23000): Column 'user_id' in where clause is ambigous"

When you are JOINing tables and doing a SELECT on the joined column, there
should be nothing ambigous about it.

On a totally different subject.

Is there any good reason for having a separate 'administrators' table, with
just 1 column, instead of just adding a 1bit yes/no column to the 'users'
table ??

I know it is more ´correct´ according to database theory, but database theory
was written when people were trying to save diskspace at all cost (including
increased CPU overhead and complexity of queries), and we realy don´t have
the diskspace problem in this database.

		- Ríkharður


Wifidog mailing list
Wifidog at isf.waglo.com

More information about the Wifidog mailing list