[google-appengine] Re: lower case string query

2009-01-02 Thread Webweave

In SQL, you simply compare the data value as lower or upper case,
which is the approach that is most often used to do a case-insensitive
match.

So you'd have something like:

WHEN UPPER(Mytable.myfield) = UPPER(?)

Or in Cake conditions, you'd do something like:

 '(UPPER(Mytable.myfield))' => strtoupper($value)

OR, if you know the data is stored in one case or the other, you don't
need the UPPER on the SQL.

On Dec 31 2008, 12:32 pm, Ray Malone  wrote:
> I came up with the same approach, however, this is a unclean way to
> handle it.  Is this the only option?
>
> On Dec 31, 10:42 am, "Rodrigo Moraes" 
> wrote:
>
> > On Wed, Dec 31, 2008 at 1:27 PM, Ray Malone wrote:
> > > I can't seem to find documentation on how to filter a string value and
> > > expect a lower case value.  For example if users input their names in
> > > upper and lower case I want to find the value using a lower case value
> > > later.
>
> > You'd need to store a copy of the name in lowercase, so that you can
> > filter by it.
>
> > -- rodrigo
>
>
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To post to this group, send email to google-appengine@googlegroups.com
To unsubscribe from this group, send email to 
google-appengine+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en
-~--~~~~--~~--~--~---



[google-appengine] Re: lower case string query

2008-12-31 Thread Ray Malone

I came up with the same approach, however, this is a unclean way to
handle it.  Is this the only option?

On Dec 31, 10:42 am, "Rodrigo Moraes" 
wrote:
> On Wed, Dec 31, 2008 at 1:27 PM, Ray Malone wrote:
> > I can't seem to find documentation on how to filter a string value and
> > expect a lower case value.  For example if users input their names in
> > upper and lower case I want to find the value using a lower case value
> > later.
>
> You'd need to store a copy of the name in lowercase, so that you can
> filter by it.
>
> -- rodrigo
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To post to this group, send email to google-appengine@googlegroups.com
To unsubscribe from this group, send email to 
google-appengine+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en
-~--~~~~--~~--~--~---



[google-appengine] Re: lower case string query

2008-12-31 Thread Rodrigo Moraes

On Wed, Dec 31, 2008 at 1:27 PM, Ray Malone wrote:
> I can't seem to find documentation on how to filter a string value and
> expect a lower case value.  For example if users input their names in
> upper and lower case I want to find the value using a lower case value
> later.

You'd need to store a copy of the name in lowercase, so that you can
filter by it.

-- rodrigo

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To post to this group, send email to google-appengine@googlegroups.com
To unsubscribe from this group, send email to 
google-appengine+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en
-~--~~~~--~~--~--~---