[Dbix-class] Index length using DBIx::Class

Peter Rabbitson rabbit+dbic at rabbit.us
Thu Jan 9 06:30:58 GMT 2014


On Wed, Jan 08, 2014 at 05:53:09PM +0100, Simon Lenne wrote:
> Hello,
> 
> I'm using DBIx::Class to add an index to my SQL table by using sqlt_deploy_hook method but I can't find a way to specify the length of that index.
> Is it possible to do that?
> 

This is a limitation of the underlying DDL manipulation library. Quoting 
from [1] (the status quo is still the same):

I'm sorry, SQL::Translator simply doesn't understand how to produce 
index declarations with lengths, which means that DBIC deploy and DBICDH 
can't do it either, since they do their work through SQLT. If you want 
to come by irc.perl.org #sql-translator and discuss how this feature 
would work and what the interface would be, it might get added, but 
currently it's not possible.

[1] http://stackoverflow.com/a/6860528

Cheers




More information about the DBIx-Class mailing list