use ->do instead of ->prepare_cached in oracle's connected() too
Rafael Kitover [Wed, 1 Jul 2009 14:03:22 +0000 (14:03 +0000)]
lib/DBIx/Class/Storage/DBI/Oracle/Generic.pm
lib/DBIx/Class/Storage/DBI/Sybase/Base.pm

index 7eadf44..ee356aa 100644 (file)
@@ -99,16 +99,13 @@ sub connected {
 
   if (not $self->next::method(@_)) {
     return 0;
-  }
-  else {
+  } else {
     my $dbh = $self->_dbh;
 
     local $dbh->{RaiseError} = 1;
 
     eval {
-      my $ping_sth = $dbh->prepare_cached("select 1 from dual");
-      $ping_sth->execute;
-      $ping_sth->finish;
+      $dbh->do("select 1 from dual");
     };
 
     return $@ ? 0 : 1;
index 4dcea42..e1ebe88 100644 (file)
@@ -6,7 +6,7 @@ use warnings;
 =head1 NAME
 
 DBIx::Class::Storage::DBI::Sybase::Base - Common functionality for drivers using
-L<DBD::Sybase>
+DBD::Sybase
 
 =head1 METHODS