|
Posted by MattMika on 08/24/07 17:10
On Fri, 24 Aug 2007 18:46:55 +0200, Rik <luiheidsgoeroe@hotmail.com>
wrote:
>Huh?
>'%b. %D, %Y' seems OK to me, why bother breaking it apart (which would
>result in an error in mysql).
>
>> Date, events_title as Event, events_description as Description FROM
>> events ORDER BY Date ASC");
>>
>> The DATE_FORMAT() is somehow messing with the sprintf so I need to
>> figure out why and Im good. Off to find my solution!
>
>Use %% for every % in the date format string.
>
>$sql = sprintf("SELECT DATE_FORMAT(events_date, '%%b. %%D, %%Y') as Date,
>events_title as Event, events_description as Description FROM events ORDER
>BY Date ASC");
>
>Then again, if this is your real statement, why even bother with the
>sprintf()? Only usefull for inserting/updating/searching on 'unknown'
>variables.
I am taking the sprintf out, I was not paying very good attn. Since Im
not sending variables from Flash to the query it is not needed. Thanks
for your help.
Matt Mika
Navigation:
[Reply to this message]
|