Re: case insensitive selects



jeff@xxxxxxxxxxxxxx (Jeff Zucker) writes:

> Radomir Hejl wrote:
>
>>Hello,
>>does DBD::CSV supports the following select clause?
>>
>>select * from table where upper (col1) like '%ab%';
>>
>>
> Yes that syntax is supported, although, I think you might want LOWER
> (col1) instead of UPPER since the example you show will never find any
> matches. Also, BTW, SQL::Statement's CLIKE operator is a
> case-insensitive version of LIKE so you can use it also, though the
> method you show is more portable.

My fault with upper... I didn't know about clike.

>>I'd like to make case insensitive queries but from docs it seems
>>it's not allowed.
>>
> Could you let me know where you found that in the docs, I'll change
> it. Also, please make sure that you have the latest version of
> SQL::Statement since all of DBD::CSV's SQL comes from that module and
> that's the module that contains the docs on what SQL is supported.

I searched through SQL::Statement docs, in particular in
an sql syntax/select paragraph and there's no upper/lower mention.
I have 1.11 version.

Thanks for clarification.
Radek
.



Relevant Pages