Thanks Chad.  I'll have to do some more coding to resolve my issue.

On 8/1/07, Chad Gray <[EMAIL PROTECTED]> wrote:
>
> With query of query you don't have database functions like LEFT() because
> you are not running your query on a database engine like MS SQL or MySQL.
>
> Do a CF left() function when you output your data.
>
>
>
> -----Original Message-----
> From: Dae [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, August 01, 2007 1:17 PM
> To: CF-Talk
> Subject: cfquery error, help please.
>
> What's wrong with my SQL statement?
>
> <cfquery dbtype="query" name="calander">
> SELECT LEFT(filename,3) as mnth, filename FROM dir_data
> where filename like '%calendar%'
> </cfquery>
>
> This the LEFT is causing an error.  Anyone know what might be the fix or
> problem?
>
> The error itself is:
>
> *Query Of Queries syntax error.*
> Encountered "LEFT. Incorrect Select List, Incorrect select column,
>
> BTW, what I'm doing is trying to grab the latest file based on the month
> in
> the file name. The naming convention for the files are Jan07Calander.doc
>   I
> can't just take the max because when a file like Aug07Calander.doc is
> placed
> in the directory, it won't pick it up.
>
> Thanks..
>
>
>
>
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
ColdFusion 8 - Build next generation apps
today, with easy PDF and Ajax features - download now
http://download.macromedia.com/pub/labs/coldfusion/cf8_beta_whatsnew_052907.pdf

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:285098
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

Reply via email to