X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2Fcdr%2FImport.pm;fp=FS%2FFS%2Fcdr%2FImport.pm;h=e788712c402f44a68eadc60ee32515d452b3cc61;hb=d5c89b967ff6685e3e7ff363a563102f8b7ef420;hp=472e2206270aff244bf10d5152b8a1b1c444bde0;hpb=dd671563e488044645ab388468f7b2f82fb15fc4;p=freeside.git diff --git a/FS/FS/cdr/Import.pm b/FS/FS/cdr/Import.pm index 472e22062..e788712c4 100644 --- a/FS/FS/cdr/Import.pm +++ b/FS/FS/cdr/Import.pm @@ -83,7 +83,7 @@ sub dbi_import { #my @cols = values %{ $args{column_map} }; my $sql = "SELECT * FROM $table "; # join(',', @cols). " FROM $table ". $sql .= 'LEFT JOIN '. $args{status_table}. - ' USING ( '. $args{primary_key}. ' )' + " ON ( $table.$pkey = ". $args{status_table}. ".$pkey )" if $args{status_table}; $sql .= ' WHERE freesidestatus IS NULL ';