created storage method to execute a coderef using master storage only, changed tnx_do...
[dbsrgits/DBIx-Class.git] / lib / DBIx / Class / Storage / DBI / Oracle / Generic.pm
index 808e20f..07abe57 100644 (file)
@@ -63,26 +63,6 @@ sub _dbh_get_autoinc_seq {
   $self->throw_exception("Unable to find a sequence INSERT trigger on table '" . $source->name . "'.");
 }
 
-=head2 insert
-
-Fetch nextval from sequence and handle insert statement.
-
-=cut
-
-sub insert {
-  my ( $self, $source, $to_insert ) = @_;
-  foreach my $col ( $source->columns ) {
-    if ( !defined $to_insert->{$col} ) {
-      my $col_info = $source->column_info($col);
-
-      if ( $col_info->{auto_nextval} ) {
-        $to_insert->{$col} = $self->_sequence_fetch( 'nextval', $col_info->{sequence} || $self->_dbh_get_autoinc_seq($self->dbh, $source) );
-      }
-    }
-  }
-  $self->next::method( $source, $to_insert );
-}
-
 sub _sequence_fetch {
   my ( $self, $type, $seq ) = @_;
   my ($id) = $self->dbh->selectrow_array("SELECT ${seq}.${type} FROM DUAL");
@@ -98,7 +78,7 @@ Returns the sequence name for an autoincrement column
 sub get_autoinc_seq {
   my ($self, $source, $col) = @_;
     
-  $self->dbh_do($self->can('_dbh_get_autoinc_seq'), $source, $col);
+  $self->dbh_do('_dbh_get_autoinc_seq', $source, $col);
 }
 
 =head2 columns_info_for