Line 0
Link Here
|
0 |
- |
1 |
use Modern::Perl; |
|
|
2 |
|
3 |
return { |
4 |
bug_number => "BUG_NUMBER", |
5 |
description => "A single line description", |
6 |
up => sub { |
7 |
my ($args) = @_; |
8 |
my ( $dbh, $out ) = @$args{qw(dbh out)}; |
9 |
|
10 |
# Do you stuffs here |
11 |
$dbh->do(q{ |
12 |
ALTER TABLE biblio_framework |
13 |
ADD COLUMN parent_frameworkcode VARCHAR(4) DEFAULT NULL AFTER frameworkcode, |
14 |
ADD CONSTRAINT biblio_framework_fk_1 FOREIGN KEY (parent_frameworkcode) REFERENCES biblio_framework (frameworkcode) ON DELETE SET NULL ON UPDATE CASCADE |
15 |
}); |
16 |
|
17 |
# Print useful stuff here |
18 |
# tables |
19 |
say $out "Added column 'parent_frameworkcode' to table 'biblio_framework'"; |
20 |
}, |
21 |
}; |