[Dbix-class] DBIC::Schema::Loader::DBI::SQLite unique constraint
Brandon Black
blblack at gmail.com
Mon Apr 9 13:34:03 GMT 2007
On 4/9/07, Hideo Kimura <hide at hide-k.net> wrote:
> Hi,
>
> Current version of DBIC::Schema::Loader::DBI::SQLite search UNIQUE
> constraint case sesitive without 'i' option in regex.
> which means,
>
> create table users (
> username text not null UNIQUE,
> ...
>
> is ok, add_unique_constraint works automatically.
>
> however,
>
> create table users (
> username text not null unique,
> ...
>
> doesn't work.
>
> Is there any reason?
> I'm just curious, because other constraint (ex. FOREIGN) is not case
> sensitive.
>
It's just a bug, I'll fix it. The SQLite.pm in Loader is some of the
oldest code in there, it dates back to DBIx::Class::Loader and hasn't
ever really been properly refactored. It's very fragile :)
-- Brandon
More information about the Dbix-class
mailing list