Skip Menu |

This queue is for tickets about the DBIx-Class CPAN distribution.

Report information
The Basics
Id: 47891
Status: resolved
Worked: 30 min
Priority: 0/
Queue: DBIx-Class

People
Owner: Nobody in particular
Requestors: ddascalescu+perl [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: Critical
Broken in: 0.08108
Fixed in: 0.08110



Subject: Cookbook entry for adding indexes incorrect about determining producer type
I'm trying to add an index to a table, and the index's definition depends on the underlying database type (support for retarded MySQL, to be more precise). http://search.cpan.org/perldoc?DBIx::Class::Manual::Cookbook#Adding_Indexes_And_Functions_To_Your_SQL claims that one can "change the index depending on the type of the database for which SQL is being generated" and gives this code example: my ($db_type = $sqlt_table->schema->translator->producer_type) =~ s/^SQL::Translator::Producer:://; However, $sqlt_table->schema->translator->producer_type returns 'CODE'. Is there another way to determine the underlying database in sqlt_deploy_hook?
Attached a standalone test.
Download 86sqlt_deploy_hook.rar
application/octet-stream 1016b

Message body not shown because it is not plain text.

This should be fixed in trunk by [1]. Please give it a spin. [1] http://dev.catalyst.perl.org/svnweb/bast/revision?rev=7344