From a78763128755515bb324f14e91630582ef9cfa0d Mon Sep 17 00:00:00 2001 From: Jean-Marie Renouard Date: Fri, 3 Mar 2023 15:46:52 +0100 Subject: [PATCH] nice looking CSV format --- mysqltuner.pl | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mysqltuner.pl b/mysqltuner.pl index 36da443..1007d43 100755 --- a/mysqltuner.pl +++ b/mysqltuner.pl @@ -1053,6 +1053,9 @@ sub select_csv_file { my @result =select_array($req); open( my $fh, '>', $tfile ) or die "Could not open file '$tfile' $!"; for my $l (@result) { + $l=~s/\t/","/g; + $l=~s/^/"/; + $l=~s/$/"/; print $fh $l; } close $fh;