Re: Strange Query Error...

From: Date: Sat, 27 Nov 2010 18:44:35 +0000
Subject: Re: Strange Query Error...
References: 1 2 3  Groups: php.db php.general 
Request: Send a blank email to php-db+get-47507@lists.php.net to get a copy of this message
On Sat, Nov 27, 2010 at 13:18, Don Wieland <donw@dwdataconcepts.com> wrote: > On Nov 27, 2010, at 10:07 AM, Bastien wrote: > >> Try removing the backticks around the table names. If you do use them, >> then all values (field names and table names) need it. > > I tried that and still chokes... > > select m.* from Members m inner join Member_Years my on m.aucciim_id = > my.member_id where now() < DATE_ADD(DATE_SUB(concat(member_year + > 1,'-07-01'), INTERVAL 1 DAY), INTERVAL 30 DAY) AND m.Preferred_First_Name > LIKE 'Don%' group by m.AUCCIIM_ID order by m.preferred_last_name > > ERROR: You have an error in your SQL syntax; check the manual that > corresponds to your MySQL server version for the right syntax to use near > 'AND m.Preferred_First_Name LIKE 'Don%'' at line 1 Note how you keep changing case here. For example, m.aucciim_id vs. m.AUCCIIM_ID. Also note that all of this is cAsE-sEnSiTiVe. -- </Daniel P. Brown> Dedicated Servers, Cloud and Cloud Hybrid Solutions, VPS, Hosting (866-) 725-4321 http://www.parasane.net/

« previous php.db (#47507) next »