Does Name exist as a column in your table, or is it a ColdFusion variable?

I know very little about how ColdFusion works, but it does parse the query, and alter it, before it gets sent to ODBC. Just looks like it's using ucase(Name) as a coldfusion function, then replacing it in the query.

Just something to look into. You would probably have much better luck with a ColdFusion list

Chris

Steve Grosz wrote:

I am writing this by hand, and is being used within Coldfusion.

MySql is v 4.1.7 and I am connecting via ODBC.

Steve

<[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]


Your sample query is not valid SQL. What tool/language are you using to
run this query? There must be something interpreting what you entered and
mis-representing your query to the MySQL server. Without that piece of the
puzzle I am completely in the dark.

It would also help to know what version MySQL server you are using and if
you are connecting to your MySQL server through any kind of library
(connector/J, ODBC, etc.) which one and what version is it?

Shawn Green
Database Administrator
Unimin Corporation - Spruce Pine

Steve Grosz <[EMAIL PROTECTED]> wrote on 12/03/2004 12:58:30 PM:



I am kinda new to SQL, and am having a problem trying to get something


done.


I'm trying to search for usernames in one of my tables.  The name is
stored as firstname lastname.

I wrote my query as
select Cust_ID, Cust_Name
from mailings
where ucase(Name) = ucase(Cust_Name)

When it runs, I get a 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 'Grosz =
Cust_Name' at line 3

It seems that its only searching for the name after the space between
the first and last name.

How can I correct this in the query?

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]










--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]



Reply via email to