update getAttribs with delimitcol

git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@8615 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
lissav 2011-01-11 18:56:49 +00:00
parent 238834c1a3
commit 9d31ce3f41

View File

@ -3199,17 +3199,10 @@ sub getAttribs
my @exeargs;
foreach (keys %keypairs)
{
my $dkeypair= &delimitcol($_);
if ($keypairs{$_})
{
if ($xcatcfg =~ /^mysql:/) { #for mysql
$statement .= q(`) . $_ . q(`) . " = ? and "
} else {
if (($xcatcfg =~ /^DB2:/) || ($xcatcfg =~ /^Pg:/)) {
$statement .= q(") . $_ . q(") . " = ? and "
} else { # for other dbs
$statement .= "$_ = ? and ";
}
}
$statement .= $dkeypair . " = ? and ";
if (ref($keypairs{$_}))
{ #correct for XML process mangling if occurred
push @exeargs, $keypairs{$_}->[0];
@ -3221,15 +3214,7 @@ sub getAttribs
}
else
{
if ($xcatcfg =~ /^mysql:/) { #for mysql
$statement .= q(`) . $_ . q(`) . " is NULL and " ;
} else {
if (($xcatcfg =~ /^DB2:/) || ($xcatcfg =~ /^Pg:/)) {
$statement .= q(") . $_ . q(") . " is NULL and " ;
} else { # for other dbs
$statement .= "$_ is NULL and ";
}
}
$statement .= $dkeypair . " is NULL and " ;
}
}
if ($xcatcfg =~ /^mysql:/) { #for mysql