projects
/
freeside.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
b74af92
)
quoting fix for asterisk v12+ CDRs stored in Pg, RT#83146
author
Ivan Kohler
<ivan@freeside.biz>
Thu, 29 Aug 2019 21:42:24 +0000
(14:42 -0700)
committer
Ivan Kohler
<ivan@freeside.biz>
Thu, 29 Aug 2019 21:42:24 +0000
(14:42 -0700)
FS/bin/freeside-cdr-asterisk_sql
patch
|
blob
|
history
diff --git
a/FS/bin/freeside-cdr-asterisk_sql
b/FS/bin/freeside-cdr-asterisk_sql
index
7e3c447
..
2c42045
100755
(executable)
--- a/
FS/bin/freeside-cdr-asterisk_sql
+++ b/
FS/bin/freeside-cdr-asterisk_sql
@@
-56,7
+56,12
@@
if ( $engine =~ /^mysql/ ) {
my @cols = ();
if ( $opt{V} >= 12 ) {
my @cols = ();
if ( $opt{V} >= 12 ) {
- push @cols, qw( id start answer end );
+ push @cols, qw( id start answer );
+ if ( $engine =~ /^Pg/ ) {
+ push @cols, "'end'";
+ } else {
+ push @cols, "end";
+ }
} else {
push @cols, qw( calldate );
}
} else {
push @cols, qw( calldate );
}
@@
-182,7
+187,7
@@
sub log_and_warn {
sub usage {
sub usage {
- "Usage: \n freeside-cdr-asterisk_sql\n\t-e mysql|Pg|... [ -H host ]n\t-D database\n\t[ -T table ]\n\t[ -V asterisk_version]\n\t-U user\n\t-P password\n\tfreesideuser\n";
+ "Usage: \n freeside-cdr-asterisk_sql\n\t-e mysql|Pg|... [ -H host ]
\
n\t-D database\n\t[ -T table ]\n\t[ -V asterisk_version]\n\t-U user\n\t-P password\n\tfreesideuser\n";
}
=head1 NAME
}
=head1 NAME