Platon Technologies
not logged in Login Registration
EnglishSlovak
open source software development celebrating 10 years of open source development! Saturday, October 17, 2026

Diff for scripts/perl/oracle/oracledump.pl between version 1.14 and 1.15

version 1.14, 2007/03/17 06:47:38 version 1.15, 2007/03/17 07:27:43
Line 1 
Line 1 
 #!/usr/bin/perl  #!/usr/bin/perl
   
 # $Platon: scripts/perl/oracle/oracledump.pl,v 1.13 2005-04-30 13:52:17 nepto Exp $  # $Platon: scripts/perl/oracle/oracledump.pl,v 1.14 2007-03-17 06:47:38 nepto Exp $
   
 use strict;  use strict;
   
Line 312  if (scalar @opt_tables < 1)
Line 312  if (scalar @opt_tables < 1)
   
 $sth = $dbh->prepare("SELECT TABLE_NAME  $sth = $dbh->prepare("SELECT TABLE_NAME
                         FROM DICTIONARY                          FROM DICTIONARY
                        WHERE TABLE_NAME = ?");                         WHERE TABLE_NAME = \'V\$INSTANCE\'");
   $sth->execute() || die $DBI::errstr;
 $sth->execute("V\$INSTANCE") || die $DBI::errstr;  
   
 ($table) = $sth->fetchrow_array();  ($table) = $sth->fetchrow_array();
   
 $sth->finish();  $sth->finish();
   
 if ($table eq "V\$INSTANCE")  if ($table eq "V\$INSTANCE")
Line 442  MARK
Line 439  MARK
                                                  data_default,                                                   data_default,
                                                  nullable                                                   nullable
                                         FROM all_tab_columns                                          FROM all_tab_columns
                                    WHERE UPPER(table_name) = ?                                     WHERE UPPER(table_name) = \''.$table.'\'
                                      AND UPPER(owner) = \''.$opt_owner.'\'';                                       AND UPPER(owner) = \''.$opt_owner.'\'';
         } else {          } else {
                 $query = 'SELECT column_name,                  $query = 'SELECT column_name,
Line 453  MARK
Line 450  MARK
                                                  data_default,                                                   data_default,
                                                  nullable                                                   nullable
                                         FROM user_tab_columns                                          FROM user_tab_columns
                                    WHERE UPPER(table_name) = ?';                                     WHERE UPPER(table_name) = \''.$table.'\'';
         }          }
   
     $sth = $dbh->prepare($query);      $sth = $dbh->prepare($query);
     $sth->execute($table) || die $DBI::errstr;      $sth->execute() || die $DBI::errstr;
   
     my $c = 0;      my $c = 0;
     while (@row = $sth->fetchrow_array())      while (@row = $sth->fetchrow_array())
Line 553  MARK
Line 550  MARK
     if ( defined $opt_owner ) {      if ( defined $opt_owner ) {
                 $query = 'SELECT column_name                  $query = 'SELECT column_name
                                         FROM all_tab_columns                                          FROM all_tab_columns
                                    WHERE UPPER(table_name) = ?                                     WHERE UPPER(table_name) = \''.$table.'\'
                                      AND UPPER(owner) = \''.$opt_owner.'\'';                                       AND UPPER(owner) = \''.$opt_owner.'\'';
         } else {          } else {
                 $query = 'SELECT column_name                  $query = 'SELECT column_name
                                         FROM user_tab_columns                                          FROM user_tab_columns
                                    WHERE UPPER(table_name) = ?';                                     WHERE UPPER(table_name) = \''.$table.'\'';
         }          }
   
         $sth = $dbh->prepare($query);          $sth = $dbh->prepare($query);
         $sth->execute($table) || die $DBI::errstr;          $sth->execute() || die $DBI::errstr;
   
         while (@row = $sth->fetchrow_array())          while (@row = $sth->fetchrow_array())
         {          {

Legend:
Removed from v.1.14  
changed lines
  Added in v.1.15

Platon Group <platon@platon.org> http://platon.org/
Copyright © 2002-2006 Platon Group
Site powered by Metafox CMS
Go to Top