[Catalyst] Catalyst and Oracle

Matt S Trout dbix-class at trout.me.uk
Mon Aug 15 21:56:51 CEST 2005


On Mon, Aug 15, 2005 at 03:21:43PM -0400, Simon Miner wrote:
> I tried setting this up as you suggested.  (I needed to install
> Class::DBI::Sweet first.)  But now I'm getting this error.
> 
> Caught exception "UUID features not available at
> /usr/local/lib/perl5/site_perl/5.8.3/Class/DBI/Sweet.pm line 590, <DATA>
> line 1."
> 
> Any thoughts?  Here is my updated CDBI.pm and Page.pm code.  (I put the
> sequence-setup code in the table-specific class as I would like to use a
> different sequence for each table.)

Blast, I thought we'd put a release out since that was fixed. Either install
Data::UUID or use the version of Sweet out of svn trunk - or change your
copy of Sweet.pm to look like

#----------------------------------------------------------------------
# UNIVERSALLY UNIQUE IDENTIFIERS
#----------------------------------------------------------------------

sub _next_in_sequence {
    my $self = shift;

    if ( lc $self->sequence eq 'uuid' ) {

        die "UUID features not available" unless $UUID_Is_Available;

        if ( $^O eq 'MSWin32' ) {
            return Win32API::GUID::CreateGuid();
        }
        else {
            return Data::UUID->new->create_str;
        }
    }

    return $self->SUPER::_next_in_sequence;
}

I suspect the version on your machine has the check before the if.

-- 
     Matt S Trout           Website: http://www.shadowcatsystems.co.uk
  Technical Director        E-mail:  mst (at) shadowcatsystems.co.uk
Shadowcat Systems Ltd.

 + Help us build a better perl ORM: http://dbix-class.shadowcatsystems.co.uk/ +



More information about the Catalyst mailing list