perlquestion
chinaxing
I have two configure file defined by perl hash:
<code>
#file1: read as $conf_file1
{
db => {
name => 'pdte',
host => 'localhost',
}
}
#file2: read as $conf_file2
{
db => {
port => '5432',
user => 'pdte_usr',
password => 'pdte_213456',
}
}
my $new_conf = { %$conf_file1, %conf_file2 }
</code>
<p>
but this type of merge can only merge hash level1, cannot merge higher than level1.
</p>
How can i complete this merge in perl ?