| Line 0
          
      
      
        Link Here | 
            
              |  |  | 1 | $DBversion = '19.12.00.XXX'; # will be replaced by the RM | 
            
              | 2 | if( CheckVersion( $DBversion ) ) { | 
            
              | 3 |     # you can use $dbh here like: | 
            
              | 4 |     # $dbh->do( "ALTER TABLE biblio ADD COLUMN badtaste int" ); | 
            
              | 5 |     $dbh->do( q{ | 
            
              | 6 |             INSERT IGNORE INTO systempreferences (variable,value,explanation,type) VALUES | 
            
              | 7 |                 ('MaxTotalSuggestions','','Number of total suggestions','Free'), | 
            
              | 8 |                 ('NumberOfSuggestionDays','','days','Free') | 
            
              | 9 |             }); | 
            
              | 10 |     # or perform some test and warn | 
            
              | 11 |     # if( !column_exists( 'biblio', 'biblionumber' ) ) { | 
            
              | 12 |     #    warn "There is something wrong"; | 
            
              | 13 |     # } | 
            
              | 14 |  | 
            
              | 15 |     # Always end with this (adjust the bug info) | 
            
              | 16 |     SetVersion( $DBversion ); | 
            
              | 17 |     print "Upgrade to $DBversion done (Bug 22774 - Limit Purchase Suggestion in a specified Time period)\n"; | 
            
              | 18 | } |