On 27 August 2010 16:22, Jim Morris <[email protected]> wrote:

> Is there a way within the sequel syntax to create an index that is
> case insensitive?
>
> I postgresql I do this in my raw DDL...
>
> create unique index idx_user_tbl_contact_email on user_tbl
> ( lower(contact_email) );
>
> Notice the lower(contact_email), this allows me to do case insenstive
> indexed assisted searches if I pas in a lowercased email.
>
> Thanks
>
> Jim I am by no means the brightest of light bulbs but why not use pure
ruby?

ie

altered_email = contact_email.to_lower

create unique index idx_user_tbl_contact_email on user_tbl
( altered_email);

HTH

Dave

--
> You received this message because you are subscribed to the Google Groups
> "sequel-talk" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected]<sequel-talk%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/sequel-talk?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sequel-talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sequel-talk?hl=en.

Reply via email to